Skip to main content



      Home
Home » Eclipse Projects » GEF » Dashed grid not working in GEF 3.11.0.201605020204
Dashed grid not working in GEF 3.11.0.201605020204 [message #1732503] Tue, 17 May 2016 14:38 Go to next message
Eclipse UserFriend
Last week I updated 4DIAC-IDE to Eclipse Neo M7 from Luna. Since this update my dashed lines are all drawn solid. Here is for example me code for drawing a dashed grid:


       @Override
	protected GridLayer createGridLayer() {
		return new GridLayer(){

			@Override
			protected void paintGrid(final Graphics g) {
				int origLineStyle = g.getLineStyle();
				g.setLineStyle(Graphics.LINE_CUSTOM);
				g.setLineDash(GRID_DASHES_STYLE); 
				super.paintGrid(g);
				g.setLineStyle(origLineStyle);
			}
			
		};
	}


From the Google results this should be correct. Is this an issue in draw2d?

Thanks,
Alois
Re: Dashed grid not working in GEF 3.11.0.201605020204 [message #1732574 is a reply to message #1732503] Wed, 18 May 2016 06:47 Go to previous messageGo to next message
Eclipse UserFriend
Have you tried it in an SWT standalone scenario? I would assume that its rather an SWT regression.
Re: Dashed grid not working in GEF 3.11.0.201605020204 [message #1732644 is a reply to message #1732574] Wed, 18 May 2016 08:05 Go to previous messageGo to next message
Eclipse UserFriend
Thanks for the tip. I tried it in pure SWT code and there everything works as it should.

Therefore I spent more time on why it is not working in draw2d. I could trace it down to the fact that SWTGraphics.checkPaint() (invoked by drawLine the SWT's setLineAttributes is called. The problem now is that the code of setLineAttributes seams to be broken as it will not set all lineAttributes anymore. I'll file a bug for SWT.
Re: Dashed grid not working in GEF 3.11.0.201605020204 [message #1732646 is a reply to message #1732644] Wed, 18 May 2016 08:11 Go to previous message
Eclipse UserFriend
Just noticed this is already fixed in https://bugs.eclipse.org/bugs/show_bug.cgi?id=493722
need to wait for updated SWT.
Previous Topic:Selection of elements in GEF
Next Topic:[GEF4] Menu bar on right click
Goto Forum:
  


Current Time: Wed Jul 23 16:20:58 EDT 2025

Powered by FUDForum. Page generated in 0.04922 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top