Community
Participate
Working Groups
Created attachment 154219 [details] Screenshot of Section with overlapped title The following snippet shows Section which Title text is overlapped by its Description text as shown by the attached screenshot: ... parent.setLayout(new TableWrapLayout()); Section section = toolkit.createSection(parent,Section.TITLE_BAR | Section.DESCRIPTION); section.setText("This is title"); section.setDescription("This is description below title"); TableWrapData tableWrapData = new TableWrapData(TableWrapData.FILL_GRAB); tableWrapData.colspan = 1; tableWrapData.grabHorizontal = true; section.setLayoutData(tableWrapData); ... Regards, Setya
Adding client to the Section seems to be the workaround (2nd screenshot), but why the rectangle ? ... parent.setLayout(new TableWrapLayout()); Section section = toolkit.createSection(parent,Section.TITLE_BAR | Section.DESCRIPTION); section.setText("This is title"); section.setDescription("This is description below title"); TableWrapData tableWrapData = new TableWrapData(TableWrapData.FILL_GRAB); tableWrapData.colspan = 1; tableWrapData.grabHorizontal = true; section.setLayoutData(tableWrapData); Composite container = toolkit.createComposite(section,SWT.NONE); container.setLayout(GridLayoutFactory.fillDefaults().create()); section.setClient(container); ... Setya
Created attachment 154220 [details] Screenshot of Section with client added
Setya, I think that this is a duplicate of bug 263025 that has been fixed in 1.3M3. Are you using 1.2 release? Can you confirm this?
Hi Ivan, Sorry, but I'm using 1.3M3 to reproduce this bug. Setya
Setya, I've tested your snippet in RCP and the description text is not visible if there is no client set. What is the use case of section without client control? As you mention in comment #2, setting client control fixes the problem.
Hi, In our case the Section client is displayed under certain conditions, so if those conditions are not met, we'll use the Section description to tell user about why the content client is not displayed. I guess Section description is part of client, if that's so we have no choice but always adding the Section client. In the meantime we have found workaround to avoid rectangle by using label as control description. Regards, Setya
Description control is visible only if the section is expanded and the client control is set.
Remove the workaround due to generic fix for bug 299914.
Hi, I tested this bug under M4 and it seems that this bug still there. I mean using the same snippet as above the rectangle line is still visible in the description control.
Setya, the "default" description control in Section is a Text widget. Do you have any custom ( CSS ) styling of a Text widget?
(In reply to comment #10) > Setya, the "default" description control in Section is a Text widget. Do you > have any custom ( CSS ) styling of a Text widget? Yes, I do. So the option is remove the CSS styling or use custom widget ?
... or set a Label as a description control.