I've a simple status bar in which I've several icons inside a HBox (ui drawn with fxml). These icons can be visibile or hidden due to some configuration properties in my app. I've a bind between some BooleanProperty and image.visibleProperty. The problem, as you can guess, is that when an icon in the middle disappears I've a hole. There is a property as in Android [URL] ...., that hide the node and collapse its space?
I want to do something when the treeitem collapsed or expanded,but both clicked the tree item icon and double clicked tree item can collapsed or expanded the tree item.so how to listen collapse and expand event?
I want to have a button that will include another node beyond the text and image that are part from the Button. This node as example will be a circle that I will change his color from gray to green if the button was pushed.
I try to do this with Background / BackgroundFill with no success
I tried to get access to the Pane / Region of the Button, but I can't find a way to do it.
I want to ask if there is an option to set the vertical position of the node handles of the TreeView-control.
I used a custom TreeCell factory with icons of sizes between 24 and 64 pixel and the location of the handle is regardless of the size of the icon on top of the cell. So if you got large icons the view did not look so nice.What I want is a property or something to center the handle in the cell depending on the size of the cell. Is there such an option?
treeView.setOnMouseClicked(new EventHandler<MouseEvent>() { @Override public void handle(MouseEvent mouseEvent) { if (mouseEvent.getClickCount() == 2 && mouseEvent.getButton() == MouseButton.PRIMARY) { // Some action } } });
For some reason when I click on a tab body I can also perform the listener action. How I can add additional statement to perform the action only if I select node?
I want to develop simple example in which I can select TreeView Nodes with Buttons(in some cases clicking on image and etc). I created this simple sample:
I'm trying to implement a scene with a ScrollPane in which the user can drag a node around and scale it dynamically. I have the dragging and scaling with the mouse wheel working as well as a reset zoom.
Here's my issue:
I'm having trouble with the calculations to fit the node to the width of the parent. If I zoom in or out, the fit to width does not work. If I change the window size after running fitWidth() once, the fit to width does not work the second time.
Here is my code as an SSCCE and how it works...
1. (works) Mouse wheel will zoom in and out around the mouse pointer 2. (works) Left or right mouse press to drag the rectangle around 3. (works) Left double-click to reset the zoom 4. (doesn't work) Right double-click to fit the width
My calculations to re-position the rectangle to the upper left of the pane and fit it (i.e. scale it up or down) to the width of the parent are incorrect.
I trying to make a file browser but when i try to add item to a FlowPane through me an error at runtime, look at this code if i add label with imageView when there are more than x ítem the error appear.
But if i add the label and the imageView alone the error didn't show. Ihave folder in my pc with more than 1200 file and the error always appear. Is there a way to make a flowpane or tilepane hold enough items?
If I wish to create a toolbox that looks like the toolbox as in photoshop tat some can collapse or expand, which type of button or function should I use?
And we have a class that draws a rectangle of 10 pixel height and 10 pixel width at 0,0 coordinates.
And we want to move with the arrows the rectangle but not to go off the frame.
The question is:
How can I do that if I draw another rectangle, it knows where is the other object and they not collapse. And so on, they move, but not collapse, just touch and stop.
Tried it, I get red line under it, tried to do "jframe1 jframe1 = new jframe1(variable);
jframe1.setVisible(False); still failed. all I want to do is open a different jframe which I got that to work but cant hide show me how to do it without having to emend my code I want to be able to do is in same style.
CashPaybtn.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent evt) { //System.out.println("CashPaybtn.actionPerformed, event="+evt); //TODO add your code for CashPaybtn.actionPerformed //PaymentMethod.setVisible(false);
Currently using latest netbeans and if im correct we are using methods and class runner?.. Anyways here's the code..
for method:
package MyPrograms; public class Mp3Method { public int dollars(int dollars,int remainingAmount){ return dollars = remainingAmount / 100; } public int quarters(int quarters, int remainingAmount){ return quarters = remainingAmount / 25;
Hiding the column but not removing , because i need to bring this column id to the next screen, only i do not want to show the column but internally it has to take the value to navigate the screen, but if i use below code, i am getting null pointer exception,
I'm trying to hide a JComboBox option depending if the a user has picked a certain option from a previous JComboBox.
.setVisible(false). doesn't work
String[] Dest = new String[] {"Select Destination","Crete", "Paris", "Croatia"}; String[] Accomodation = new String[] {"Select your Accomodation","Hotel", "Villa", "Bed & Breakfast","Youth Hostel"}; String[] Night = new String[] {" Select number of Nights", "7","10","14"}; final JComboBox<String> comboDest1 = new JComboBox<String>(Dest);
[Code] ....
I know setVisible isn't the way it's done but i don't know how to do it
I've made a login system with a username and a password. The password is visible and I wanna hide it, how do I do that? Here is my code (have used swing);
I have a login window, which when sucessful will activate a new Applet/JFrame. The problem is that the login window remains in the background under the new JFrame. I want this to diappear. I want to either set the visibility to false, or close it.This is how the new window is started:
if(sucess.equals("flase")){
DBAccess dba = new DBAccess(); dba.setFname(fnameusr); //fnameusr dba.setLname(lnameusr); //lnameusr dba.main(null);
//LogIn.exit(0); }else{ JOptionPane.showMessageDialog(null, "Your credentials were not entered correctly or you may not be authorised to access this system."); System.exit(0); }
I am trying to do a rock, paper, scissors game, but when i choose for example, it shows what i have typed. So how do i hide text form showing in the console?
As below code showing that you cannot directly access the private variable as i understood,
public class EncapsulationDemo{ private int ssn; private String empName; private int empAge; //Getter and Setter methods public int getEmpSSN(){ return ssn; } public String getEmpName(){ return empName;
I am generating pdf and displaying it in separate window/tab using the approach described in BalusC Code: PDF handling.I need to display blockui ajax loader when i select the commandlink to display pdf.The pdf gets generated but the ajax loader image remains as it is.I need to manually refresh the page to hide it.Is there any way using which it can be hidden as soon as the pdf gets displayed.My code snippet is as below