473,396 Members | 1,712 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Group Layout

Hello,

I'm trying to set up a panel with a group layout, and I wanted to know if I could code my groups like this:
GroupLayout menuLayout = new GroupLayout(menu);
menu.setLayout(menuLayout);
menuLayout.setHorizontalGroup(
menuLayout.createParallelGroup(GroupLayout.Alignme nt.LEADING)
mainDishes = new JLabel();
mainDishes.setFont(new Font("SansSerif", 1, 14));
mainDishes.setForeground(new Color(0,0,0));
mainDishes.setHorizontalAlignment(SwingConstants.C ENTER);
mainDishes.setText("Main Dishes");
menuPanel.add(mainDishes);
.addComponent(mainDishes, GroupLayout.Alignment.TRAILING, GroupLayout.DEFAULT_SIZE, 324, Short.MAX_VALUE)

Where I'm setting my group and then adding the components of my panel to each group respectivly, or something to that effect. I designed this in NetBeans, and I'm copying the code into TextPad because there are several things I don't understand about NetBeans and I don't have time to figure them all out before my assignment is due. Anyway, I'm looking for the most efficient way to code this, any suggestions would be appreciated.
Nov 15 '07 #1
0 1048

Sign in to post your reply or Sign up for a free account.

Similar topics

1
by: Rick | last post by:
After being frustrated with this issue on several occasions I think I found the secret sauce for solving the issue after reading a few different messages about what others thought and trying a...
2
by: Alex | last post by:
Hi all, I'm trying to create a layout of our website for Marketing to review, and though I know how I want it presented, I'm not sure how to write the SQL code to make it work. Here's a sample...
6
by: Chuck | last post by:
I have a report with three columns, accross then down, and two groups. Currently the group headers are only one column wide and appear in the left hand column. How can I make the group header be...
15
by: may_2005 | last post by:
Hello, I am working on a piece of (open source) hardware, which needs a certain amount of (open source) embedded C code developed for the hardware to perform a useful task. I am looking for...
3
by: cameron | last post by:
I need to find a user's memberOf list, (and all nested groups), very quickly. My current method is to iterate through the the results of the the MemberOf property and then do the same to each of...
10
by: Tom | last post by:
I want to be able (at run time) to center a control (like a text box) inside a group box. Whats the best way to calculate this? Is there something in the framework that tells you the area INSIDE a...
10
by: Luke | last post by:
Hi. I am trying to make correct layout, here is an example of (dynamically generated content via jsp): http://localhost/www/layout.htm Most outer div is positioned absolute (if not then it...
1
by: Rippo | last post by:
Hi I have the following FO XSL document with the following data I am trying to add sub totals for each group in a XSL document but cannnot seem to work it out! Output would be something like:-...
4
by: magedsql | last post by:
I am MCDBA, I like your group, and i need to join it as a member but i do NOT know How . Please help Thank You maged.
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.