| | |
Set Size for JSlider
![]() |
Is there anyway of actually changing the length of a slider. I have a some sliders in a grid layout and im wondering wether the grid layout will stop the sliders from expanding.
Darn so how can i make them bigger?! I feel the grid layout might be restricting the size but im not so sure.
A grid layout will give each element in it the exact same horizontal and vertical size.
If you don't want that (for example you want some controls to take up less space, think of a group of very short labels) you will have to use another layout manager that offers more flexibility like GridBagLayout.
Those are of course harder to use because of that greater flexibility.
You can still not control size directly but you can now say that your slider can run across multiple columns.
If you don't want that (for example you want some controls to take up less space, think of a group of very short labels) you will have to use another layout manager that offers more flexibility like GridBagLayout.
Those are of course harder to use because of that greater flexibility.
You can still not control size directly but you can now say that your slider can run across multiple columns.
![]() |
Similar Threads
- How to set html page size attributes (HTML and CSS)
- Setting the size for a JSlider (Java)
- Determining correct size of JDesktopPane (Java)
- Setting Console window size. (C)
- Set Performance Options in Windows XP (Windows tips 'n' tweaks)
Other Threads in the Java Forum
- Previous Thread: two compiler errors to do with arrays
- Next Thread: varible not working in for loop
| Thread Tools | Search this Thread |
2dgraphics 3d @param affinetransform android api applet application arc arguments array arrays automation banking binary bluetooth byte chat chatprogramusingobjects class client code color compare component count database design detection eclipse eclipsedevelopment encryption error fractal game givemetehcodez graphics gridlayout gui guitesting helpwithhomework html ide if_statement image input integer interface j2me java java.xls javadesktopapplications javaprojects jni jpanel julia keytool keyword linux list loop macintosh map method methods mobile netbeans newbie object os pong problem producer program programming project projectideas read recursion reference replaysolutions rim scanner server set size sms sort sql string swing terminal threads transforms tree ui unicode validation web windows






