How can stretch a background image for the label?
Hi allHow can I stretch a background image in a label?
public void start(final Stage primaryStage) {
final Label lbTest = new Label("My Test Label");
lbTest.setAlignment(Pos.CENTER);
lbTest.setTextAlignment(TextAlignment.CENTER);
lbTest.setStyle("-fx-background-color:red;-fx-background-repeat:stretch;-fx-background-position:center top;-fx-background-image:url(\"http://upload.wikimedia.org/wikipedia/commons/thumb/1/1c/BlueMarble-2001-2002.jpg/640px-BlueMarble-2001-2002.jpg\");");
final HBox hbox = new HBox();
hbox.setId("MyRootPane");
Button btnLeft=new Button("Left Button");
Button btnRight=new Button("Right Button");
hbox.getChildren().addAll(btnLeft,lbTest,btnRight);
final StackPane layout = new StackPane();
layout.getChildren().add(hbox);
Scene scene = new Scene(layout, 600, 320);
lbTest.prefWidthProperty().bind(scene.widthProperty());
lbTest.prefHeightProperty().bind(scene.heightProperty());
primaryStage.setScene(scene);
primaryStage.show();
}
This code does not work, if I deleted css - fx-background-repeat: stretching; the tense but background image he repeated, I want to leave the background image stretched and not repeated, it can be extended with the window resizing automatically.
Try - fx-background-size: stretch;
Tags: Java
Similar Questions
-
How can I change the background image for the lock screen?
Hi, I just bought a new laptop and I got Windows 7 installed in the store, and I would like to change the background image for the lock screen. When I went to activate my account, I found out that it has already been activated, but I can't find the settings-> settings more PC in the lower corner on the right. Thank you!
Lock screen?
Are you referring to the login screen?
Or wallpaper?
Right-click on your desktop and select Personalize.
Office link is at the bottom left and use a win-7 theme.
-
When I drag an image to icon URL, such as for Amazon to the dock, changes the image to an image any ordinary of the world. How can I change this image to the original Amazon icon image that existed before I moved to the docking station?
Why do you want to put the URL in the Dock, which doesn't seem like the appropriate place for this.
-
How can I get my images on the Cloud for people to buy?
How can I get my images on the Cloud for people to buy? I lost time differences and the photos and other stock video and photos. Thank you for your time.
Michael. Tmoss
Hello
On this page: frequently asked questions, Adobe Stock
-
How can I use a video for the preview looks like instead of the fixed image?
How can I use a video for the preview looks like instead of the fixed image? I use android lollipop.
Hi Ali,
Video preview for looks is not currently supported on Android. Your feature request was noted by the team.
In the meantime, there is a video on the device you want to use as an overview, I would recommend taking a perforated CAP and still image as loading preview.
Best,
Bronwyn
-
Hello
Is there an easy way to set the background image for the menu drop down and etc, current support only black as a background?
Thank you
Tom.
Welcome to the forums!
This is currently not supported unfortunately.
I encourage you to save a feature for this request:
https://www.BlackBerry.com/JIRA/secure/dashboard.jspa
See you soon!
Martin
-
How can I delete several images in the Finder at the same time
How can I delete several images in the Finder all at once rather than one by one
Click on an image and the successive images to press the SHIFT, or command key by clicking on the image to add it to the selection. Then Ctrl-click (tap two fingers) on any icon and choose to put in the trash. If the icons are in an easily selectable column or online, you can click on the window that contain, and then drag around them for a multiple selection.
-
How can I save my picture for the web and devices?
How can I save my picture for the web and devices?
I can't find the option when I want to save the image
Hi jacquelineb,
What version of Photoshop are you using?
If you are using the latest version of CC, please consult export images Adobe Photoshop for mobile and web. Tutorials Photoshop Adobe CC
Let us know if that helps.
Kind regards
Assani
-
How can I download raw images in the photos of el capitan?
How can I download raw images in the photos of el capitan?
What camera?
What happens when you try?
RAW + JPEG you use?
-
How can I recover my pc for the first time that I bought?
Hello
How can I recover my pc for the first time that I bought? because my pc is so slow... I have a compaq laptop cq61... and I want to set up the first time... How can I? I don't have a recovery disk because when I bought it dosnt have a recovery in it disc. Please help me. Thank youHello
I'm happy to help you
Glancing at the screen shot you posted, your looks of partition fine recovery (recovery (D).
Save your files on an external hard drive or flash drive (depending on how many you have).
Once that is done, disconnect all connected to your PC, but the AC adapter.
Start the PC and the HP welcome screen, press the F11 key to start the Recovery dialog box and follow the prompts.
It should take 15 to 30 minutes and your PC needs to be restored to its factory settings.
Then just reinstall all programs and files that does not come with the PC.
You will need the files or the installation of program diskettes. You cannot back up installed programs and reinstall them using a backup.
Paul
-
How can I share 'My images' with the other user accounts on my computer?
How can I share 'My images' with the other user accounts on my computer?
where are the 'experts' on these forums adverstised? I can't get an answer to a simple question. Does anyone know how to do this?
Here we are, ok, I'm not an expert, but try this:
Right click on 'My images' > share > specific people... > select that you want to share this folder with.
...
After that, try to connect by using a different account. If you will not be able to open C:\Users\"FirstUser"\Pictures, you try to extend the network in the left pane of Windows Explorer > expand ComputerName > expand users > expand "FirstUser" > photos
-
How can I change an icon for the device in Windows 7?
How can I change an icon for the device in Windows 7?
In 'Control Panel\Devices and printers' I want to change the icon of a device that there are listed.
Hi Dave Tavres
I'm afraid to say that you would not be able to change this icon.
This icon is provided by the hardware manufacturer, and is included in the drivers and architecture has no Windows allows to change this information.
However, you can use the third party applications to change. Use your favorite search engine to find on the Internet.Important note: This response contains a reference to third party World Wide Web site. Microsoft provides this information as a convenience to you. Microsoft does not control these sites and no has not tested any software or information found on these sites; Therefore, Microsoft cannot make any approach to quality, security or the ability of a software or information that are there. There are the dangers inherent in the use of any software found on the Internet, and Microsoft cautions you to make sure that you completely understand the risk before retrieving any software from the Internet.
It will be useful.
Thank you, and in what concerns:
Shekhar S - Microsoft technical support.Visit our Microsoft answers feedback Forum and let us know what you think.
-
I tried to delete some unused programs of my had drive and cleared PC wlidcl.dll How can I get this program for the PC works as before? The PC works now as slow as a snail climbs. What do you suggest me? Thank you
Norman.--
E-mail address is removed from the privacy *.
original title: wlidcl.dll
Hello
I suggest to follow the steps below and check if the problem persists:
Not one:
Uninstall Windows Live essentials followed the procedure described in the link:
http://Windows.Microsoft.com/en-us/Windows7/uninstall-or-change-a-program
Step b:
Download and install Windows Live essential from the link:
-
How can I reset Adobe Acrobat for the default settings?
How can I reset Adobe Acrobat for the default settings?
Hi sharonc7 ,
You can try to reset the preferences, here is a link on how to reset preferences: How to reset preference settings in Acrobat format.
Also. Visit this link, which deals with the same subject: How to reset Adobe to its original settings? (Acrobat Reader) .
Thank you
Shivam
-
How can I get an invoice for the purchase of the Adobe program? I live in the Mexico.
How can I get an invoice for the purchase of the Adobe program? I live in the Mexico.
Hi Angela,.
Please consult this document: print a receipt of payment or invoice for your subscription to creative cloud.
Best,
Sara
Maybe you are looking for
-
My Qosmio F60 graphics card crashes often
Hi guys. Hoping for some advice/corrections. I now have a F60 for about three weeks.The thing is great with the exception of a significant drawbacks. The screen will either sometimes go to pieces then turn black and then turns back on nothing similar
-
Graphic resolution Equium L100 186
It is a new satellite L100-186, I installed Win XP Proffesional. I am steel not shore-style witch it is, because the toshiba Web page, it gives me series two options L10 and L20, but readers for the L10 will not work but works of L20? In any case, I
-
CLIQ 2.1: email notification
does anyone else have a boring song as they are notified by email after the update? so annoying! I was trying to sleep and he kept playing. I was too tired to understand what it was, so I turned my phone off and studied this morning.
-
Using Windows XP and OE6. I want to open the folder to archive and get the messages back to my Inbox.
-
'C0000005' exception Access Violation error when I open application of embroidery
In order to open my application of embroidery (which is used to run), I get the following: Exception code: C0000005 Exception flags: 0 The exception address: 00614ED8 Number of settings: 2 Start address: 0048CA 00 Exception offset: 001884DB What can