Download
Getting Started
Members
Projects
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
More
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
Toggle navigation
Bugzilla – Attachment 57256 Details for
Bug 171223
Under gtk/Linux always all figures of the FigureCanvas are repainted (if double buffering is not disabled)
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
Terms of Use
|
Copyright Agent
Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read
this important communication.
Program showing the problem
Main.java (text/x-java), 1.74 KB, created by
Micha Riser
on 2007-01-22 09:50:07 EST
(
hide
)
Description:
Program showing the problem
Filename:
MIME Type:
Creator:
Micha Riser
Created:
2007-01-22 09:50:07 EST
Size:
1.74 KB
patch
obsolete
>import org.eclipse.draw2d.*; >import org.eclipse.draw2d.Label; >import org.eclipse.swt.layout.FillLayout; >import org.eclipse.swt.widgets.*; > >/* > * Created on 22.01.2007 > */ > >public class Main { > > class VerboseLabel extends Label { > > public VerboseLabel(String string) { > super(string); > } > > @Override > public void paint(Graphics graphics) { > System.out.println("paint "+getText()); > super.paint(graphics); > } > > } > > > private FigureCanvas fFigureCanvas; > > void setUp() throws InterruptedException { > > Display display = Display.getDefault(); > > Shell shell = new Shell(display); > > shell.setLayout(new FillLayout()); > > LightweightSystem lws = new LightweightSystem(); > > //fFigureCanvas = new FigureCanvas(shell, SWT.NONE, lws); > fFigureCanvas = new FigureCanvas(shell, lws); > > fFigureCanvas.setLayout(new FillLayout()); > > Figure composite = new Figure(); > fFigureCanvas.setContents(composite); > composite.setLayoutManager(new FlowLayout(false)); > > composite.add(new VerboseLabel("label 1")); > composite.add(new VerboseLabel("label 2")); > composite.add(new VerboseLabel("label 3")); > final VerboseLabel verboseLabel = new VerboseLabel("label 4"); > composite.add(verboseLabel); > composite.add(new VerboseLabel("label 5")); > composite.add(new VerboseLabel("label 6")); > > shell.open(); > > Thread.sleep(100); > > while(display.readAndDispatch()) {} > > System.out.println("request repaint of "+verboseLabel.getText()); > verboseLabel.repaint(); > > while(display.readAndDispatch()) {} > > display.dispose(); > > } > > public static void main(String[] args) throws InterruptedException { > > new Main().setUp(); > > } > >}
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 171223
: 57256