Hi Peppe,
here are some hints about the changes you want to achieve,
Implementation may depends on if you want to display
1) the current scale, or also
2) the future scale when the user is dragging to change scale
But anyway, I don't think you need to display the scale each time the
mouse is moved by any CursorTool.
Moreover, I think it will not work if you use plugins instead of
cursortools to change scale (ex zoom on layer).
Did you see the Viewport and the ViewportListener class in the
com.vividsolutions.jump.workbench.uipackage
for 1) I'm sure you can add a listener to the viewport to track each
time a zoom operation is performed and change
the displayed scale when it is necessary, not more.
For 2), you may need to track mouse motion, but in my opinion, it should
take place in the DragTool
performing the zoom, not in the abstract class which is common to every
tool.
Not sure my vision of the UI code is clear enough to give you good
advice, but take a litle time to explore
the LayerViewPanel and the Viewport, and to ask more information to
other programmers (I think Matthias
has a good experience about this part of the code).
Michaël
Le 18/02/2012 15:37, Giuseppe Aruta a écrit :
Hi all,
I made some small modifications to add a new panel on info bar. This
panel shows the scale when the cursor moves on the view.
I modified these classes:
com.vividsolutions.jump.workbench.ui.WorkbenchFrame ( to add a new panel)
com.vividsolutions.jump.workbench.ui.cursortool.AbstractCursorTool (to
allow to show permanently the scale whenever the cursor moves on the view)
I tested these modification only on Linux Ubuntu and Windows 7.
Since I modified original classes from Jump, I am not sure if I
violate some kind of copyrights. Any comment will be welcome.
regards
Giuseppe
------------------------------------------------------------------------------
Virtualization& Cloud Management Using Capacity Planning
Cloud computing makes use of virtualization - but cloud computing
also focuses on allowing computing to be delivered as a service.
http://www.accelacomm.com/jaw/sfnl/114/51521223/
_______________________________________________
Jump-pilot-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel
------------------------------------------------------------------------------
Virtualization & Cloud Management Using Capacity Planning
Cloud computing makes use of virtualization - but cloud computing
also focuses on allowing computing to be delivered as a service.
http://www.accelacomm.com/jaw/sfnl/114/51521223/
_______________________________________________
Jump-pilot-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel