[JPP-Devel] SVN: [5294] core/trunk

2016-12-29 Thread jump-pilot-svn
Revision: 5294
  http://sourceforge.net/p/jump-pilot/code/5294
Author:   michaudm
Date: 2016-12-29 12:25:19 + (Thu, 29 Dec 2016)
Log Message:
---
Implement FR 250 : update a layer from another using an attribute join

Modified Paths:
--
core/trunk/scripts/default-plugins.xml
core/trunk/src/language/jump.properties
core/trunk/src/language/jump_cz.properties
core/trunk/src/language/jump_de.properties
core/trunk/src/language/jump_es.properties
core/trunk/src/language/jump_fi.properties
core/trunk/src/language/jump_fr.properties
core/trunk/src/language/jump_hu.properties
core/trunk/src/language/jump_it.properties
core/trunk/src/language/jump_ja_JP.properties
core/trunk/src/language/jump_ml.properties
core/trunk/src/language/jump_pt.properties
core/trunk/src/language/jump_pt_BR.properties
core/trunk/src/language/jump_ta_IN.properties
core/trunk/src/language/jump_te.properties
core/trunk/src/language/jump_zh_CN.properties
core/trunk/src/language/jump_zh_HK.properties

Added Paths:
---
core/trunk/src/org/openjump/core/ui/plugin/tools/UpdateWithJoinPlugIn.java

Modified: core/trunk/scripts/default-plugins.xml
===
--- core/trunk/scripts/default-plugins.xml  2016-12-28 14:58:30 UTC (rev 
5293)
+++ core/trunk/scripts/default-plugins.xml  2016-12-29 12:25:19 UTC (rev 
5294)
@@ -824,12 +824,16 @@

org.openjump.core.ui.plugin.tools.JoinTableFromExistingLayerPlugIn


-   
org.openjump.core.ui.plugin.tools.BeanshellAttributeCalculatorPlugIn
+   org.openjump.core.ui.plugin.tools.UpdateWithJoinPlugIn


org.openjump.core.ui.plugin.tools.JoinTablePlugIn

+   
+   
org.openjump.core.ui.plugin.tools.BeanshellAttributeCalculatorPlugIn
+   
 
+


org.openjump.core.ui.plugin.tools.SimplifyWithJTSAlgorithmPlugIn

Modified: core/trunk/src/language/jump.properties
===
--- core/trunk/src/language/jump.properties 2016-12-28 14:58:30 UTC (rev 
5293)
+++ core/trunk/src/language/jump.properties 2016-12-29 12:25:19 UTC (rev 
5294)
@@ -1556,6 +1556,23 @@
 
org.openjump.core.ui.plugin.tools.SplitPolygonPlugIn.Must-select-one-polygon-and-one-linestring
 = Must select one polygon and one linestring.
 
org.openjump.core.ui.plugin.tools.SplitPolygonPlugIn.Update-the-polygon-with-result
 = Update the polygon with result.
 
org.openjump.core.ui.plugin.tools.SplitPolygonPlugIn.Uses-the-selected-linestring-to-cut-the-selected-polygon-into-separate-sections
 = Uses the selected linestring to cut the selected polygon into separate 
sections.
+org.openjump.core.ui.plugin.tools.UpdateWithJoinPlugIn = Update Layer with an 
Attribute Join
+org.openjump.core.ui.plugin.tools.UpdateWithJoinPlugIn.Attributes-mapping-is-not-defined
 = Attributes mapping is not defined
+org.openjump.core.ui.plugin.tools.UpdateWithJoinPlugIn.Choose-layers = Choose 
layers
+org.openjump.core.ui.plugin.tools.UpdateWithJoinPlugIn.Description = Update 
reference layer attribute values with join layer attribute values when 
reference feature ext id = join feature id.\n\
+  Join attributes can be mapped to reference attributes even if their names 
differ.\n\
+  Left join keep reference feature which do not verify the join condition 
while right join add features from join layer which do not verify the join 
condition.
+org.openjump.core.ui.plugin.tools.UpdateWithJoinPlugIn.Do-not-join = Do not 
join
+org.openjump.core.ui.plugin.tools.UpdateWithJoinPlugIn.Join-layer = Join layer
+org.openjump.core.ui.plugin.tools.UpdateWithJoinPlugIn.Join-layer-id = Join 
layer id
+org.openjump.core.ui.plugin.tools.UpdateWithJoinPlugIn.Join-layer-id-is-not-unique
 = Join layer id is not unique
+org.openjump.core.ui.plugin.tools.UpdateWithJoinPlugIn.Left-join = Left join
+org.openjump.core.ui.plugin.tools.UpdateWithJoinPlugIn.Left-join-tooltip = 
Check left join to keep all reference features
+org.openjump.core.ui.plugin.tools.UpdateWithJoinPlugIn.Map-attributes = Map 
attributes
+org.openjump.core.ui.plugin.tools.UpdateWithJoinPlugIn.Reference-layer-ext-id 
= Reference layer external id
+org.openjump.core.ui.plugin.tools.UpdateWithJoinPlugIn.Reference-layer-to-update
 = Reference layer to update
+org.openjump.core.ui.plugin.tools.UpdateWithJoinPlugIn.Right-join = Right join
+org.openjump.core.ui.plugin.tools.UpdateWithJoinPlugIn.Right-join-tooltip = 
Check right join to add un-joined features from join layer
 org.openjump.core.ui.plugin.tools.ZoomRealtimeTool.Zoom-Realtime = Zoom 
Realtime
 
org.openjump.core.ui.plugin.tools.generate.AbstractLinearReferencingPlugIn.add-end-point
 = Add end point
 
org.openjump.core.ui.plugin.tools.generate.AbstractLinearReferencingPlugIn.distance-unit
 = Distance Unit

[JPP-Devel] next OJ release (warming up)

2016-12-29 Thread edgar . soldin
hey All,

i am going to start to condense Changelog into Changes.txt. how is the state 
with the topics you guys wanted to fix/add before that? here's the list from 
Mike a while ago with some statuses added

OPEN (let's release anyway)
#430 and #444 : Image reader - Probably hard to tackle, Ede/Jukka have the best 
expertise in this area.

#440 FIXED
#419 #389 OPEN (let's release anyway)
UI bugs : these bugs are probably still there but difficult to reproduce (hence 
to solve).
Finding reproducible cases would be useful.

OPEN (Mike?)
#429 : writing a consistent prj file with shapefile. I have started working on 
this bug

FIXED
#427 : Test broken - Maybe Ede will have a look as I think the regression is 
related to plugin management,
but there is probably much to do on tests and any help is welcome !

#425 works for me (Mike?)
#421 looking into it
: minor UI problems

#422 OPEN (let's release anyway)
: bug needing a jython expert

SaveWizard
i will cleanup SaveWizard into "Save Dataset As (testing)", showing only file 
saving. advanced options for specific writers (eg. csv) will probably not make 
it into the release, as it seems not to be trivial to add those. but to get 
first impressions/bug reports i think we need to get it out there.

anything else? ..ede

--
Check out the vibrant tech community on one of the world's most 
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
___
Jump-pilot-devel mailing list
Jump-pilot-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel


[JPP-Devel] SVN: [5295] core/trunk/src/com/vividsolutions/jump/workbench/model/ UndoableEditReceiver.java

2016-12-29 Thread jump-pilot-svn
Revision: 5295
  http://sourceforge.net/p/jump-pilot/code/5295
Author:   edso
Date: 2016-12-29 17:32:49 + (Thu, 29 Dec 2016)
Log Message:
---
disable unneeded asserts

Modified Paths:
--

core/trunk/src/com/vividsolutions/jump/workbench/model/UndoableEditReceiver.java

Modified: 
core/trunk/src/com/vividsolutions/jump/workbench/model/UndoableEditReceiver.java
===
--- 
core/trunk/src/com/vividsolutions/jump/workbench/model/UndoableEditReceiver.java
2016-12-29 12:25:19 UTC (rev 5294)
+++ 
core/trunk/src/com/vividsolutions/jump/workbench/model/UndoableEditReceiver.java
2016-12-29 17:32:49 UTC (rev 5295)
@@ -80,7 +80,7 @@
  * undo history will be truncated.
  */
 public void reportNothingToUndoYet() {
-Assert.isTrue(isReceiving());
+//Assert.isTrue(isReceiving());
 setNothingToUndoReported(true);
 }
 
@@ -90,7 +90,7 @@
  * of an UndoableCommand, leaving it partially complete and 
non-unexecutable.
  */
 public void reportIrreversibleChange() {
-Assert.isTrue(isReceiving());
+//Assert.isTrue(isReceiving());
 irreversibleChangeReported = true;
 }
 
@@ -141,7 +141,7 @@
  * it should simply not call this method; the undo history will be cleared.
  */
 public void receive(UndoableEdit undoableEdit) {
-Assert.isTrue(isReceiving());
+//Assert.isTrue(isReceiving());
 
 //Don't add the UndoableEdit to the UndoManager right away; the caller 
may
 //call #clearNewUndoableEdits. [Jon Aquino]


--
Check out the vibrant tech community on one of the world's most 
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
___
Jump-pilot-devel mailing list
Jump-pilot-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel


[JPP-Devel] SVN: [5296] core/trunk/src/com/vividsolutions/jump/workbench/ui/zoom/ ZoomToCoordinatePlugIn.java

2016-12-29 Thread jump-pilot-svn
Revision: 5296
  http://sourceforge.net/p/jump-pilot/code/5296
Author:   edso
Date: 2016-12-29 17:33:41 + (Thu, 29 Dec 2016)
Log Message:
---
reformat
removed unneeded undo call

Modified Paths:
--

core/trunk/src/com/vividsolutions/jump/workbench/ui/zoom/ZoomToCoordinatePlugIn.java

Modified: 
core/trunk/src/com/vividsolutions/jump/workbench/ui/zoom/ZoomToCoordinatePlugIn.java
===
--- 
core/trunk/src/com/vividsolutions/jump/workbench/ui/zoom/ZoomToCoordinatePlugIn.java
2016-12-29 17:32:49 UTC (rev 5295)
+++ 
core/trunk/src/com/vividsolutions/jump/workbench/ui/zoom/ZoomToCoordinatePlugIn.java
2016-12-29 17:33:41 UTC (rev 5296)
@@ -24,96 +24,96 @@
 import com.vividsolutions.jump.workbench.ui.cursortool.Animations;
 
 public class ZoomToCoordinatePlugIn extends AbstractPlugIn {
-   private Coordinate lastCoordinate = new Coordinate(0, 0);
-   public boolean execute(PlugInContext context) throws Exception {
-   reportNothingToUndoYet(context);
-   Coordinate coordinate = prompt(context);
-   if (coordinate == null) {
-   return false;
-   }
-lastCoordinate = coordinate;
-   context.getLayerViewPanel().getViewport()
-   .zoom(toEnvelope(coordinate, 
context.getLayerManager()));
-
Animations.drawExpandingRing(context.getLayerViewPanel().getViewport()
-   .toViewPoint(lastCoordinate), false, Color.BLUE,
-   context.getLayerViewPanel(), new float[] { 20, 20 });
+  private Coordinate lastCoordinate = new Coordinate(0, 0);
 
-   return true;
-   }
+  public boolean execute(PlugInContext context) throws Exception {
+Coordinate coordinate = prompt(context);
+if (coordinate == null) {
+  return false;
+}
+lastCoordinate = coordinate;
+context.getLayerViewPanel().getViewport()
+.zoom(toEnvelope(coordinate, context.getLayerManager()));
+Animations.drawExpandingRing(context.getLayerViewPanel().getViewport()
+.toViewPoint(lastCoordinate), false, Color.BLUE,
+context.getLayerViewPanel(), new float[] { 20, 20 });
 
-   private Coordinate prompt(PlugInContext context) {
-   while (true) {
-   try {
-   return 
toCoordinate(JOptionPane.showInputDialog(context
-   .getWorkbenchFrame(),
-   
I18N.get("ui.zoom.ZoomToCoordinatePlugIn.enter-coordinate-to-zoom-to"), 
lastCoordinate.x + ", "
-   + 
lastCoordinate.y));
-   } catch (Exception e) {
-   
JOptionPane.showMessageDialog(context.getWorkbenchFrame(), e
-   .getMessage(),
-   
context.getWorkbenchFrame().getTitle(),
-   JOptionPane.ERROR_MESSAGE);
-   }
-   }
+return true;
+  }
 
-   }
+  private Coordinate prompt(PlugInContext context) {
+while (true) {
+  try {
+return toCoordinate(JOptionPane.showInputDialog(context
+.getWorkbenchFrame(), I18N
+.get("ui.zoom.ZoomToCoordinatePlugIn.enter-coordinate-to-zoom-to"),
+lastCoordinate.x + ", " + lastCoordinate.y));
+  } catch (Exception e) {
+JOptionPane.showMessageDialog(context.getWorkbenchFrame(),
+e.getMessage(), context.getWorkbenchFrame().getTitle(),
+JOptionPane.ERROR_MESSAGE);
+  }
+}
 
-   private Envelope toEnvelope(Coordinate coordinate, LayerManager 
layerManager) {
-   int segments = 0;
-   int segmentSum = 0;
-   outer : for (Iterator i = layerManager.iterator(); i.hasNext(); 
) {
-   Layer layer = (Layer) i.next();
-   for (Iterator j = 
layer.getFeatureCollectionWrapper().iterator(); j
-   .hasNext(); ) {
-   Feature feature = (Feature) j.next();
-Collection coordinateArrays = 
CoordinateArrays.toCoordinateArrays(feature.getGeometry(), false);
-for (Iterator k = coordinateArrays.iterator(); k.hasNext(); ) {
-   Coordinate[] coordinates = (Coordinate[]) k.next();
-for (int a = 1; a < coordinates.length; a++) {
-segments++;
-   segmentSum += coordinates[a].distance(coordinates[a-1]);
-if (segments > 100) { break outer; }
-}
-}
-   }
-   }
-   Envelope envelope = new Envelope(coordi

[JPP-Devel] OSGeoLive 10.5 Alpha1

2016-12-29 Thread Brian M Hamlin

 Hi All JUMP'ers  You may be interested to know that OSGeo Live, a reference 
implementation of OSGeo stack software and others on LUbuntu Linux, is in Alpha 
testing this week. If the schedule permits, it would be "awesome"to have a new 
OpenJUMP on the next release (in about a month or so). Please speak up on the 
OSGeo Live mailing list [0] if you have any questions or concerns, and looking 
forward to a new OpenJUMP in New Year.thanks and best regards from Berkeley, 
California  --Brian M HamlinOSGeo Live PSC[0]  
https://lists.osgeo.org/mailman/listinfo/live-demo

--
Check out the vibrant tech community on one of the world's most 
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
___
Jump-pilot-devel mailing list
Jump-pilot-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel


Re: [JPP-Devel] OSGeoLive 10.5 Alpha1

2016-12-29 Thread edgar . soldin
On 29.12.2016 18:39, Brian M Hamlin wrote:
> 
>  Hi All JUMP'ers  You may be interested to know that OSGeo Live, a reference 
> implementation of OSGeo stack software and others on LUbuntu Linux, is in 
> Alpha testing this week. If the schedule permits, it would be "awesome"to 
> have a new OpenJUMP on the next release (in about a month or so). Please 
> speak up on the OSGeo Live mailing list [0] if you have any questions or 
> concerns, and looking forward to a new OpenJUMP in New Year.thanks and best 
> regards from Berkeley, California  --Brian M HamlinOSGeo Live PSC[0]  
> https://lists.osgeo.org/mailman/listinfo/live-demo
> 

we are currently working on the next release. what is your deadline? ..ede/OJ

--
Check out the vibrant tech community on one of the world's most 
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
___
Jump-pilot-devel mailing list
Jump-pilot-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel


[JPP-Devel] SVN: [5297] core/trunk/src

2016-12-29 Thread jump-pilot-svn
Revision: 5297
  http://sourceforge.net/p/jump-pilot/code/5297
Author:   edso
Date: 2016-12-29 18:16:49 + (Thu, 29 Dec 2016)
Log Message:
---
enhance and i18n error handling

Modified Paths:
--

core/trunk/src/com/vividsolutions/jump/workbench/ui/zoom/ZoomToCoordinatePlugIn.java
core/trunk/src/language/jump.properties
core/trunk/src/language/jump_cz.properties
core/trunk/src/language/jump_de.properties
core/trunk/src/language/jump_es.properties
core/trunk/src/language/jump_fi.properties
core/trunk/src/language/jump_fr.properties
core/trunk/src/language/jump_hu.properties
core/trunk/src/language/jump_it.properties
core/trunk/src/language/jump_ja_JP.properties
core/trunk/src/language/jump_ml.properties
core/trunk/src/language/jump_pt.properties
core/trunk/src/language/jump_pt_BR.properties
core/trunk/src/language/jump_ta_IN.properties
core/trunk/src/language/jump_te.properties
core/trunk/src/language/jump_zh_CN.properties
core/trunk/src/language/jump_zh_HK.properties

Modified: 
core/trunk/src/com/vividsolutions/jump/workbench/ui/zoom/ZoomToCoordinatePlugIn.java
===
--- 
core/trunk/src/com/vividsolutions/jump/workbench/ui/zoom/ZoomToCoordinatePlugIn.java
2016-12-29 17:33:41 UTC (rev 5296)
+++ 
core/trunk/src/com/vividsolutions/jump/workbench/ui/zoom/ZoomToCoordinatePlugIn.java
2016-12-29 18:16:49 UTC (rev 5297)
@@ -10,6 +10,7 @@
 import com.vividsolutions.jts.geom.Coordinate;
 import com.vividsolutions.jts.geom.Envelope;
 import com.vividsolutions.jump.I18N;
+import com.vividsolutions.jump.JUMPException;
 import com.vividsolutions.jump.feature.Feature;
 import com.vividsolutions.jump.geom.EnvelopeUtil;
 import com.vividsolutions.jump.util.CoordinateArrays;
@@ -27,10 +28,29 @@
   private Coordinate lastCoordinate = new Coordinate(0, 0);
 
   public boolean execute(PlugInContext context) throws Exception {
-Coordinate coordinate = prompt(context);
+Coordinate coordinate = null;
+boolean retry = true;
+while (retry) {
+  try {
+String value = JOptionPane
+.showInputDialog(
+context.getWorkbenchFrame(),
+
I18N.get("ui.zoom.ZoomToCoordinatePlugIn.enter-coordinate-to-zoom-to"),
+lastCoordinate.x + ", " + lastCoordinate.y);
+if (value == null) {
+  retry = false;
+} else {
+  coordinate = toCoordinate(value);
+}
+  } catch (Exception e) {
+context.getWorkbenchContext().getErrorHandler().handleThrowable(e);
+  }
+}
+
 if (coordinate == null) {
   return false;
 }
+
 lastCoordinate = coordinate;
 context.getLayerViewPanel().getViewport()
 .zoom(toEnvelope(coordinate, context.getLayerManager()));
@@ -41,22 +61,6 @@
 return true;
   }
 
-  private Coordinate prompt(PlugInContext context) {
-while (true) {
-  try {
-return toCoordinate(JOptionPane.showInputDialog(context
-.getWorkbenchFrame(), I18N
-.get("ui.zoom.ZoomToCoordinatePlugIn.enter-coordinate-to-zoom-to"),
-lastCoordinate.x + ", " + lastCoordinate.y));
-  } catch (Exception e) {
-JOptionPane.showMessageDialog(context.getWorkbenchFrame(),
-e.getMessage(), context.getWorkbenchFrame().getTitle(),
-JOptionPane.ERROR_MESSAGE);
-  }
-}
-
-  }
-
   private Envelope toEnvelope(Coordinate coordinate, LayerManager 
layerManager) {
 int segments = 0;
 int segmentSum = 0;
@@ -90,22 +94,21 @@
   }
 
   private Coordinate toCoordinate(String s) throws Exception {
-if (s == null) {
-  return null;
-}
-if (s.trim().length() == 0) {
-  return null;
-}
 s = StringUtil.replaceAll(s, ",", " ");
 StringTokenizer tokenizer = new StringTokenizer(s);
+if (tokenizer.countTokens() < 2) {
+  throw new JUMPException(
+  I18N.get("ui.zoom.ZoomToCoordinatePlugIn.enter-two-values"));
+}
+
 String x = tokenizer.nextToken();
-if (!StringUtil.isNumber(x)) {
-  throw new Exception("Not a number: " + x);
-}
+if (!StringUtil.isNumber(x))
+  throw new 
JUMPException(I18N.getMessage("ui.zoom.ZoomToCoordinatePlugIn.{0}-is-not-a-number",
 x));
+
 String y = tokenizer.nextToken();
-if (!StringUtil.isNumber(y)) {
-  throw new Exception("Not a number: " + y);
-}
+if (!StringUtil.isNumber(y))
+  throw new 
JUMPException(I18N.getMessage("ui.zoom.ZoomToCoordinatePlugIn.{0}-is-not-a-number",
 y));
+
 return new Coordinate(Double.parseDouble(x), Double.parseDouble(y));
   }
 

Modified: core/trunk/src/language/jump.properties
===
--- core/trunk/src/language/jump.properties 2016-12-29 17:33:41 UTC (rev 
5296)
+++ core/trunk/src/language/jump.properties 2016-12-29 18:16:49 UTC (

[JPP-Devel] SVN: [5298] core/trunk/src/language/jump_fr.properties

2016-12-29 Thread jump-pilot-svn
Revision: 5298
  http://sourceforge.net/p/jump-pilot/code/5298
Author:   michaudm
Date: 2016-12-29 18:42:56 + (Thu, 29 Dec 2016)
Log Message:
---
update french I18 file

Modified Paths:
--
core/trunk/src/language/jump_fr.properties

Modified: core/trunk/src/language/jump_fr.properties
===
--- core/trunk/src/language/jump_fr.properties  2016-12-29 18:16:49 UTC (rev 
5297)
+++ core/trunk/src/language/jump_fr.properties  2016-12-29 18:42:56 UTC (rev 
5298)
@@ -2751,8 +2751,8 @@
 ui.plugin.analysis.GeometryFunction.Remove-Holes=Supprimer les trous
 ui.plugin.analysis.GeometryFunction.Remove-Small-Holes=Supprimer les petits 
trous
 ui.plugin.analysis.GeometryFunction.Remove-Small-Segments=Simplifier 
(Supprimer les petits segments)
-GeoJSONWriter.writing-features=#T:Writing features...
-Reader.parsed-{0}-features=#T:Parsed {0} features.
+GeoJSONWriter.writing-features=Ecriture des objets...
+Reader.parsed-{0}-features={0} objets lus.
 ui.GenericNames.interior-point-intersects=le point int\xE9rieur intersecte
 ui.GenericNames.intersects-interior-point=intersecte le point int\xE9rieur
 org.openjump.core.ui.plugin.queries.Operator.intip=intersecte le point 
int\xE9rieur
@@ -2779,5 +2779,5 @@
 
org.openjump.core.ui.plugin.tools.UpdateWithJoinPlugIn.Reference-layer-to-update=Couche
 de r\xE9f\xE9rence \xE0 mettre \xE0 jour
 org.openjump.core.ui.plugin.tools.UpdateWithJoinPlugIn.Right-join=Jointure 
droite
 org.openjump.core.ui.plugin.tools.UpdateWithJoinPlugIn.Right-join-tooltip=La 
jointure droite ajoute au r\xE9sultat les objets non-joints de la couche jointes
-ui.zoom.ZoomToCoordinatePlugIn.enter-two-values=#T:Enter two values!
-ui.zoom.ZoomToCoordinatePlugIn.{0}-is-not-a-number=#T:''{0}'' is not a number!
\ No newline at end of file
+ui.zoom.ZoomToCoordinatePlugIn.enter-two-values=Entrez deux valeurs!
+ui.zoom.ZoomToCoordinatePlugIn.{0}-is-not-a-number=''{0}'' n''est pas un 
nombre!
\ No newline at end of file


--
Check out the vibrant tech community on one of the world's most 
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
___
Jump-pilot-devel mailing list
Jump-pilot-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel


[JPP-Devel] SVN: [5299] core/trunk/src

2016-12-29 Thread jump-pilot-svn
Revision: 5299
  http://sourceforge.net/p/jump-pilot/code/5299
Author:   edso
Date: 2016-12-29 18:54:16 + (Thu, 29 Dec 2016)
Log Message:
---
reformatting, removed tabs
scale is a double value now, same as internally
some beautification of the dialog

Modified Paths:
--
core/trunk/src/language/jump.properties
core/trunk/src/org/openjump/core/ui/plugin/view/ZoomToScalePlugIn.java

Modified: core/trunk/src/language/jump.properties
===
--- core/trunk/src/language/jump.properties 2016-12-29 18:42:56 UTC (rev 
5298)
+++ core/trunk/src/language/jump.properties 2016-12-29 18:54:16 UTC (rev 
5299)
@@ -1727,7 +1727,7 @@
 org.openjump.core.ui.plugin.view.ViewOptionsPlugIn.Date-format = Date format
 org.openjump.core.ui.plugin.view.ViewOptionsPlugIn.Selection-synchronization = 
Synchronization of Selection between the Attribute Table and the Map
 org.openjump.core.ui.plugin.view.ViewOptionsPlugIn.Synchronize = Synchronize
-org.openjump.core.ui.plugin.view.ZoomToScalePlugIn.actual-scale-in-horizontal-direction
 = Actual Scale in Horizontal Direction
+org.openjump.core.ui.plugin.view.ZoomToScalePlugIn.actual-scale-in-horizontal-direction
 = Current Scale in Horizontal Direction
 org.openjump.core.ui.plugin.view.ZoomToScalePlugIn.scale = scale
 org.openjump.core.ui.plugin.view.ZoomToScalePlugIn.set-new-scale-to-zoom = Set 
New Scale to Zoom
 org.openjump.core.ui.plugin.view.ZoomToScalePlugIn.zoom-to-scale = Zoom to 
Scale

Modified: core/trunk/src/org/openjump/core/ui/plugin/view/ZoomToScalePlugIn.java
===
--- core/trunk/src/org/openjump/core/ui/plugin/view/ZoomToScalePlugIn.java  
2016-12-29 18:42:56 UTC (rev 5298)
+++ core/trunk/src/org/openjump/core/ui/plugin/view/ZoomToScalePlugIn.java  
2016-12-29 18:54:16 UTC (rev 5299)
@@ -37,6 +37,10 @@
 
 package org.openjump.core.ui.plugin.view;
 
+import java.text.DecimalFormat;
+
+import javax.swing.JTextField;
+
 import org.openjump.core.ui.util.ScreenScale;
 
 import com.vividsolutions.jts.geom.Coordinate;
@@ -54,7 +58,6 @@
 import com.vividsolutions.jump.workbench.ui.MultiInputDialog;
 import com.vividsolutions.jump.workbench.ui.Viewport;
 
-
 /**
  * Zooms to a given map scale, received from a input dialog
  * 
@@ -62,88 +65,96 @@
  */
 public class ZoomToScalePlugIn extends AbstractPlugIn {
 
-private String T1 = "scale"; //[sstein] this string is not used anymore
-int scale = 25000;
-double oldHorizontalScale = 0; // is calculated for panel-width (not 
heigth!!)
-double modelWidth = 0;
-double panelWidth = 0;
-String text 
=I18N.get("org.openjump.core.ui.plugin.view.ZoomToScalePlugIn.set-new-scale-to-zoom")
 + ":  1 : ";
+  private String T1 = "scale"; // [sstein] this string is not used anymore
+  double scale = 25000;
+  double oldHorizontalScale = 0; // is calculated for panel-width (not 
heigth!!)
+  double modelWidth = 0;
+  double panelWidth = 0;
+  String text = I18N
+  
.get("org.openjump.core.ui.plugin.view.ZoomToScalePlugIn.set-new-scale-to-zoom")
+  + " 1:";
 
-public void initialize(PlugInContext context) throws Exception {
-   
-   this.T1 = 
I18N.get("org.openjump.core.ui.plugin.view.ZoomToScalePlugIn.scale") + ": ";
-   context.getFeatureInstaller().addMainMenuItem(this,
-   new String[]
-   {MenuNames.VIEW},
-   
I18N.get("org.openjump.core.ui.plugin.view.ZoomToScalePlugIn.zoom-to-scale")+"{pos:9}",
 
-   false, 
-   null, 
-   createEnableCheck(context.getWorkbenchContext()));
-}
-
-public static MultiEnableCheck createEnableCheck(
-WorkbenchContext workbenchContext) {
-EnableCheckFactory checkFactory = new EnableCheckFactory(
-workbenchContext);
+  public void initialize(PlugInContext context) throws Exception {
 
-return new MultiEnableCheck().add(checkFactory
-.createAtLeastNLayerablesMustExistCheck(1));
+this.T1 = I18N
+.get("org.openjump.core.ui.plugin.view.ZoomToScalePlugIn.scale") + ": 
";
+context
+.getFeatureInstaller()
+.addMainMenuItem(
+this,
+new String[] { MenuNames.VIEW },
+
I18N.get("org.openjump.core.ui.plugin.view.ZoomToScalePlugIn.zoom-to-scale")
++ "{pos:9}", false, null,
+createEnableCheck(context.getWorkbenchContext()));
+  }
+
+  public static MultiEnableCheck createEnableCheck(
+  WorkbenchContext workbenchContext) {
+EnableCheckFactory checkFactory = new EnableCheckFactory(workbenchContext);
+
+return new MultiEnableCheck().add(checkFactory
+.createAtLeastNLayerablesMustExistCheck(1));
+  }
+
+  public boolean execute(PlugInContext context) throws Exception {
+
+Viewport port = context.getL

[JPP-Devel] Transformation in OpenJump ...

2016-12-29 Thread manf...@egger-gis.at
Hi,

I will held my presenation about OpenJump and transformation in German, but i 
plan to write a summary for your WIKI in English. There are some not German 
speaking people there.

One important question about the Transformation Plugin by 
https://github.com/orbisgis/cts:

Some days ago i transformed coordinates between two datums (WGS 84 to 
MGI(Austria)). The transformation was ok. But i was suprised that it is not 
necessary to select a geographic transformation.

In other software you have to select a geographic transformation to get a 
correct transformation. 

What is the reason? 

Best regards

Manfred





--
Check out the vibrant tech community on one of the world's most 
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
___
Jump-pilot-devel mailing list
Jump-pilot-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel


[JPP-Devel] SVN: [5300] core/trunk/src/com/vividsolutions/jump/workbench/ui/ WorkbenchFrame.java

2016-12-29 Thread jump-pilot-svn
Revision: 5300
  http://sourceforge.net/p/jump-pilot/code/5300
Author:   edso
Date: 2016-12-29 19:13:28 + (Thu, 29 Dec 2016)
Log Message:
---
replace introduced doubled functionality by simply using the plugins themselves

Modified Paths:
--
core/trunk/src/com/vividsolutions/jump/workbench/ui/WorkbenchFrame.java

Modified: 
core/trunk/src/com/vividsolutions/jump/workbench/ui/WorkbenchFrame.java
===
--- core/trunk/src/com/vividsolutions/jump/workbench/ui/WorkbenchFrame.java 
2016-12-29 18:54:16 UTC (rev 5299)
+++ core/trunk/src/com/vividsolutions/jump/workbench/ui/WorkbenchFrame.java 
2016-12-29 19:13:28 UTC (rev 5300)
@@ -63,7 +63,6 @@
 import java.util.Iterator;
 import java.util.Map;
 import java.util.Set;
-import java.util.StringTokenizer;
 
 import javax.swing.BorderFactory;
 import javax.swing.DefaultDesktopManager;
@@ -97,26 +96,22 @@
 import javax.swing.event.PopupMenuListener;
 import javax.swing.text.JTextComponent;
 
+import org.apache.commons.lang3.StringUtils;
 import org.apache.log4j.Level;
 import org.openjump.core.CheckOS;
 import org.openjump.core.model.TaskEvent;
 import org.openjump.core.model.TaskListener;
+import org.openjump.core.ui.plugin.view.ZoomToScalePlugIn;
 import org.openjump.core.ui.swing.DetachableInternalFrame;
 import org.openjump.core.ui.util.ScreenScale;
 import org.openjump.swing.factory.component.ComponentFactory;
 
-import com.vividsolutions.jts.geom.Coordinate;
 import com.vividsolutions.jts.geom.Envelope;
-import com.vividsolutions.jts.geom.Geometry;
-import com.vividsolutions.jts.geom.GeometryFactory;
 import com.vividsolutions.jts.util.Assert;
 import com.vividsolutions.jump.I18N;
-import com.vividsolutions.jump.feature.Feature;
-import com.vividsolutions.jump.geom.EnvelopeUtil;
 import com.vividsolutions.jump.util.Blackboard;
 import com.vividsolutions.jump.util.Block;
 import com.vividsolutions.jump.util.CollectionUtil;
-import com.vividsolutions.jump.util.CoordinateArrays;
 import com.vividsolutions.jump.util.StringUtil;
 import com.vividsolutions.jump.workbench.JUMPWorkbench;
 import com.vividsolutions.jump.workbench.Logger;
@@ -137,9 +132,9 @@
 import com.vividsolutions.jump.workbench.model.WMSLayer;
 import com.vividsolutions.jump.workbench.plugin.AbstractPlugIn;
 import com.vividsolutions.jump.workbench.plugin.EnableCheck;
+import com.vividsolutions.jump.workbench.plugin.EnableChecked;
 import com.vividsolutions.jump.workbench.plugin.PlugIn;
 import com.vividsolutions.jump.workbench.plugin.PlugInContext;
-import com.vividsolutions.jump.workbench.ui.cursortool.Animations;
 import com.vividsolutions.jump.workbench.ui.cursortool.editing.EditingPlugIn;
 import com.vividsolutions.jump.workbench.ui.images.IconLoader;
 import com.vividsolutions.jump.workbench.ui.plugin.FeatureInstaller;
@@ -149,6 +144,7 @@
 import com.vividsolutions.jump.workbench.ui.renderer.style.ChoosableStyle;
 import com.vividsolutions.jump.workbench.ui.task.TaskMonitorManager;
 import com.vividsolutions.jump.workbench.ui.toolbox.ToolboxDialog;
+import com.vividsolutions.jump.workbench.ui.zoom.ZoomToCoordinatePlugIn;
 
 /**
  * This class is responsible for the main window of the JUMP application.
@@ -233,6 +229,8 @@
 private JPanel statusPanel;
 private JTextArea messageText;
 private JLabel timeLabel, memoryLabel, scaleLabel, coordinateLabel;
+private ZoomToScalePlugIn zoomToScalePlugin = new ZoomToScalePlugIn();
+private ZoomToCoordinatePlugIn zoomToCoordPlugin = new 
ZoomToCoordinatePlugIn();
 
 private String lastStatusMessage = "";
 
@@ -1509,13 +1507,7 @@
 public void mouseClicked(MouseEvent e) {
 if (e.getClickCount() != 2)
 return;
-try {
-zoomScale_actionPerformed(e);
-} catch (Exception e1) {
-// TODO Auto-generated catch block
-e1.printStackTrace();
-}
-
+executePlugin(zoomToScalePlugin);
 }
 });
 
@@ -1525,13 +1517,8 @@
 public void mouseClicked(MouseEvent e) {
 if (e.getClickCount() != 2)
 return;
-try {
-zoomCoordinates_actionPerformed(e);
-} catch (Exception e1) {
-// TODO Auto-generated catch block
-e1.printStackTrace();
-}
 
+executePlugin(zoomToCoordPlugin);
 }
 });
 
@@ -2278,154 +2265,20 @@
 }
 }
 
-// [Giuseppe Aruta 2016_6_4] the following method derives from ZoomToScale
-// plugin
-void zoomScale_actionPerformed(MouseEvent e) throws Exception {
-Viewport port = getActiveTaskFrame().getLayerViewPanel().getViewport();
-
-double oldHorizontalScale = ScreenScale.getHorizontalMapScale(port);
-int scale = 25000;
- 

[JPP-Devel] duplicated code in WorkbenchFrame

2016-12-29 Thread edgar . soldin
hey Peppe,

i cleaned up some code you duplicated while adding plugin functions to the 
statusbar. for future reference please check how i did it and try to do it 
similarily next time.
you have a tendency to copy/paste ;) when you can simply call the code from 
where it is already.

regards ..ede

 Forwarded Message 
Subject: [JPP-Devel] SVN: [5300] 
core/trunk/src/com/vividsolutions/jump/workbench/ui/ WorkbenchFrame.java
Date: Thu, 29 Dec 2016 19:13:28 +
From: jump-pilot-...@lists.sourceforge.net
Reply-To: OpenJump develop and use 
To: jump-pilot-devel@lists.sourceforge.net

Revision: 5300
  http://sourceforge.net/p/jump-pilot/code/5300
Author:   edso
Date: 2016-12-29 19:13:28 + (Thu, 29 Dec 2016)
Log Message:
---
replace introduced doubled functionality by simply using the plugins themselves

Modified Paths:
--
core/trunk/src/com/vividsolutions/jump/workbench/ui/WorkbenchFrame.java

Modified: 
core/trunk/src/com/vividsolutions/jump/workbench/ui/WorkbenchFrame.java
===
--- core/trunk/src/com/vividsolutions/jump/workbench/ui/WorkbenchFrame.java 
2016-12-29 18:54:16 UTC (rev 5299)
+++ core/trunk/src/com/vividsolutions/jump/workbench/ui/WorkbenchFrame.java 
2016-12-29 19:13:28 UTC (rev 5300)
@@ -63,7 +63,6 @@
 import java.util.Iterator;
 import java.util.Map;
 import java.util.Set;
-import java.util.StringTokenizer;
 
 import javax.swing.BorderFactory;
 import javax.swing.DefaultDesktopManager;
@@ -97,26 +96,22 @@
 import javax.swing.event.PopupMenuListener;
 import javax.swing.text.JTextComponent;
 
+import org.apache.commons.lang3.StringUtils;
 import org.apache.log4j.Level;
 import org.openjump.core.CheckOS;
 import org.openjump.core.model.TaskEvent;
 import org.openjump.core.model.TaskListener;
+import org.openjump.core.ui.plugin.view.ZoomToScalePlugIn;
 import org.openjump.core.ui.swing.DetachableInternalFrame;
 import org.openjump.core.ui.util.ScreenScale;
 import org.openjump.swing.factory.component.ComponentFactory;
 
-import com.vividsolutions.jts.geom.Coordinate;
 import com.vividsolutions.jts.geom.Envelope;
-import com.vividsolutions.jts.geom.Geometry;
-import com.vividsolutions.jts.geom.GeometryFactory;
 import com.vividsolutions.jts.util.Assert;
 import com.vividsolutions.jump.I18N;
-import com.vividsolutions.jump.feature.Feature;
-import com.vividsolutions.jump.geom.EnvelopeUtil;
 import com.vividsolutions.jump.util.Blackboard;
 import com.vividsolutions.jump.util.Block;
 import com.vividsolutions.jump.util.CollectionUtil;
-import com.vividsolutions.jump.util.CoordinateArrays;
 import com.vividsolutions.jump.util.StringUtil;
 import com.vividsolutions.jump.workbench.JUMPWorkbench;
 import com.vividsolutions.jump.workbench.Logger;
@@ -137,9 +132,9 @@
 import com.vividsolutions.jump.workbench.model.WMSLayer;
 import com.vividsolutions.jump.workbench.plugin.AbstractPlugIn;
 import com.vividsolutions.jump.workbench.plugin.EnableCheck;
+import com.vividsolutions.jump.workbench.plugin.EnableChecked;
 import com.vividsolutions.jump.workbench.plugin.PlugIn;
 import com.vividsolutions.jump.workbench.plugin.PlugInContext;
-import com.vividsolutions.jump.workbench.ui.cursortool.Animations;
 import com.vividsolutions.jump.workbench.ui.cursortool.editing.EditingPlugIn;
 import com.vividsolutions.jump.workbench.ui.images.IconLoader;
 import com.vividsolutions.jump.workbench.ui.plugin.FeatureInstaller;
@@ -149,6 +144,7 @@
 import com.vividsolutions.jump.workbench.ui.renderer.style.ChoosableStyle;
 import com.vividsolutions.jump.workbench.ui.task.TaskMonitorManager;
 import com.vividsolutions.jump.workbench.ui.toolbox.ToolboxDialog;
+import com.vividsolutions.jump.workbench.ui.zoom.ZoomToCoordinatePlugIn;
 
 /**
  * This class is responsible for the main window of the JUMP application.
@@ -233,6 +229,8 @@
 private JPanel statusPanel;
 private JTextArea messageText;
 private JLabel timeLabel, memoryLabel, scaleLabel, coordinateLabel;
+private ZoomToScalePlugIn zoomToScalePlugin = new ZoomToScalePlugIn();
+private ZoomToCoordinatePlugIn zoomToCoordPlugin = new 
ZoomToCoordinatePlugIn();
 
 private String lastStatusMessage = "";
 
@@ -1509,13 +1507,7 @@
 public void mouseClicked(MouseEvent e) {
 if (e.getClickCount() != 2)
 return;
-try {
-zoomScale_actionPerformed(e);
-} catch (Exception e1) {
-// TODO Auto-generated catch block
-e1.printStackTrace();
-}
-
+executePlugin(zoomToScalePlugin);
 }
 });
 
@@ -1525,13 +1517,8 @@
 public void mouseClicked(MouseEvent e) {
 if (e.getClickCount() != 2)
 return;
-try {
-zoomCoordinates_actionPerformed(e);
-} catch (Exception e1) {
-

Re: [JPP-Devel] next OJ release (warming up)

2016-12-29 Thread Michaël Michaud
Hi,

Le 29/12/2016 à 17:27, edgar.sol...@web.de a écrit :
> hey All,
>
> i am going to start to condense Changelog into Changes.txt. how is the state 
> with the topics you guys wanted to fix/add before that? here's the list from 
> Mike a while ago with some statuses added
>
> OPEN (let's release anyway)
> #430 and #444 : Image reader - Probably hard to tackle, Ede/Jukka have the 
> best expertise in this area.
OK to release anyway
>
> #440 FIXED
> #419 #389 OPEN (let's release anyway)
> UI bugs : these bugs are probably still there but difficult to reproduce 
> (hence to solve).
> Finding reproducible cases would be useful.
OK to release anyway
>
> OPEN (Mike?)
> #429 : writing a consistent prj file with shapefile. I have started working 
> on this bug
I would need to include next cts release in OJ core, so, i postponed 
this fix to after 1.10 release.
>
> FIXED
> #427 : Test broken - Maybe Ede will have a look as I think the regression is 
> related to plugin management,
> but there is probably much to do on tests and any help is welcome !
>
> #425 works for me (Mike?)
Works also for me, don't know if it has been solved or it it only 
happens in very special corner cases.
> #421 looking into it
> : minor UI problems
>
> #422 OPEN (let's release anyway)
> : bug needing a jython expert
>
> SaveWizard
> i will cleanup SaveWizard into "Save Dataset As (testing)", showing only file 
> saving. advanced options for specific writers (eg. csv) will probably not 
> make it into the release, as it seems not to be trivial to add those. but to 
> get first impressions/bug reports i think we need to get it out there.
OK. Note that it also needs to be internationalized...
> anything else? ..ede
If you have time, you may have a look at 448 and 363, but none of them 
are too severe, 1.10 can be released even if they are not solved.

Michaël
>
> --
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, SlashDot.org! http://sdm.link/slashdot
> ___
> Jump-pilot-devel mailing list
> Jump-pilot-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel
>


--
Check out the vibrant tech community on one of the world's most 
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
___
Jump-pilot-devel mailing list
Jump-pilot-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel


Re: [JPP-Devel] SVN: [5296] core/trunk/src/com/vividsolutions/jump/workbench/ui/zoom/ ZoomToCoordinatePlugIn.java

2016-12-29 Thread Michaël Michaud
Hi Ede,

I don't know what you changed, but the plugin has a strange behaviour.

When the dialog is get from the menu, clicking on OK just reset the 
coordinates without zooming to it.

When the dialog is get from the status bar, it works as usually.

Michaël


Le 29/12/2016 à 18:33, jump-pilot-...@lists.sourceforge.net a écrit :
> Revision: 5296
>http://sourceforge.net/p/jump-pilot/code/5296
> Author:   edso
> Date: 2016-12-29 17:33:41 + (Thu, 29 Dec 2016)
> Log Message:
> ---
> reformat
> removed unneeded undo call
>
> Modified Paths:
> --
>  
> core/trunk/src/com/vividsolutions/jump/workbench/ui/zoom/ZoomToCoordinatePlugIn.java
>
> Modified: 
> core/trunk/src/com/vividsolutions/jump/workbench/ui/zoom/ZoomToCoordinatePlugIn.java
> ===
> --- 
> core/trunk/src/com/vividsolutions/jump/workbench/ui/zoom/ZoomToCoordinatePlugIn.java
>   2016-12-29 17:32:49 UTC (rev 5295)
> +++ 
> core/trunk/src/com/vividsolutions/jump/workbench/ui/zoom/ZoomToCoordinatePlugIn.java
>   2016-12-29 17:33:41 UTC (rev 5296)
> @@ -24,96 +24,96 @@
>   import com.vividsolutions.jump.workbench.ui.cursortool.Animations;
>   
>   public class ZoomToCoordinatePlugIn extends AbstractPlugIn {
> - private Coordinate lastCoordinate = new Coordinate(0, 0);
> - public boolean execute(PlugInContext context) throws Exception {
> - reportNothingToUndoYet(context);
> - Coordinate coordinate = prompt(context);
> - if (coordinate == null) {
> - return false;
> - }
> -lastCoordinate = coordinate;
> - context.getLayerViewPanel().getViewport()
> - .zoom(toEnvelope(coordinate, 
> context.getLayerManager()));
> -  
> Animations.drawExpandingRing(context.getLayerViewPanel().getViewport()
> - .toViewPoint(lastCoordinate), false, Color.BLUE,
> - context.getLayerViewPanel(), new float[] { 20, 20 });
> +  private Coordinate lastCoordinate = new Coordinate(0, 0);
>   
> - return true;
> - }
> +  public boolean execute(PlugInContext context) throws Exception {
> +Coordinate coordinate = prompt(context);
> +if (coordinate == null) {
> +  return false;
> +}
> +lastCoordinate = coordinate;
> +context.getLayerViewPanel().getViewport()
> +.zoom(toEnvelope(coordinate, context.getLayerManager()));
> +Animations.drawExpandingRing(context.getLayerViewPanel().getViewport()
> +.toViewPoint(lastCoordinate), false, Color.BLUE,
> +context.getLayerViewPanel(), new float[] { 20, 20 });
>   
> - private Coordinate prompt(PlugInContext context) {
> - while (true) {
> - try {
> - return 
> toCoordinate(JOptionPane.showInputDialog(context
> - .getWorkbenchFrame(),
> - 
> I18N.get("ui.zoom.ZoomToCoordinatePlugIn.enter-coordinate-to-zoom-to"), 
> lastCoordinate.x + ", "
> - + 
> lastCoordinate.y));
> - } catch (Exception e) {
> - 
> JOptionPane.showMessageDialog(context.getWorkbenchFrame(), e
> - .getMessage(),
> - 
> context.getWorkbenchFrame().getTitle(),
> - JOptionPane.ERROR_MESSAGE);
> - }
> - }
> +return true;
> +  }
>   
> - }
> +  private Coordinate prompt(PlugInContext context) {
> +while (true) {
> +  try {
> +return toCoordinate(JOptionPane.showInputDialog(context
> +.getWorkbenchFrame(), I18N
> +
> .get("ui.zoom.ZoomToCoordinatePlugIn.enter-coordinate-to-zoom-to"),
> +lastCoordinate.x + ", " + lastCoordinate.y));
> +  } catch (Exception e) {
> +JOptionPane.showMessageDialog(context.getWorkbenchFrame(),
> +e.getMessage(), context.getWorkbenchFrame().getTitle(),
> +JOptionPane.ERROR_MESSAGE);
> +  }
> +}
>   
> - private Envelope toEnvelope(Coordinate coordinate, LayerManager 
> layerManager) {
> - int segments = 0;
> - int segmentSum = 0;
> - outer : for (Iterator i = layerManager.iterator(); i.hasNext(); 
> ) {
> - Layer layer = (Layer) i.next();
> - for (Iterator j = 
> layer.getFeatureCollectionWrapper().iterator(); j
> - .hasNext(); ) {
> - Feature feature = (Feature) j.next();
> -Collection coordinateArrays = 
> CoordinateArrays.toCoordinateArrays(feature.getGeometry(), false);
> -for (Iterator k = coordinateArrays.iterator()

[JPP-Devel] SVN: [5301] core/trunk/src/com/vividsolutions/jump/workbench/ui/zoom/ ZoomToCoordinatePlugIn.java

2016-12-29 Thread jump-pilot-svn
Revision: 5301
  http://sourceforge.net/p/jump-pilot/code/5301
Author:   edso
Date: 2016-12-29 20:15:00 + (Thu, 29 Dec 2016)
Log Message:
---
fix regression

Modified Paths:
--

core/trunk/src/com/vividsolutions/jump/workbench/ui/zoom/ZoomToCoordinatePlugIn.java

Modified: 
core/trunk/src/com/vividsolutions/jump/workbench/ui/zoom/ZoomToCoordinatePlugIn.java
===
--- 
core/trunk/src/com/vividsolutions/jump/workbench/ui/zoom/ZoomToCoordinatePlugIn.java
2016-12-29 19:13:28 UTC (rev 5300)
+++ 
core/trunk/src/com/vividsolutions/jump/workbench/ui/zoom/ZoomToCoordinatePlugIn.java
2016-12-29 20:15:00 UTC (rev 5301)
@@ -41,6 +41,7 @@
   retry = false;
 } else {
   coordinate = toCoordinate(value);
+  retry = false;
 }
   } catch (Exception e) {
 context.getWorkbenchContext().getErrorHandler().handleThrowable(e);


--
Check out the vibrant tech community on one of the world's most 
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
___
Jump-pilot-devel mailing list
Jump-pilot-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel


Re: [JPP-Devel] SVN: [5296] core/trunk/src/com/vividsolutions/jump/workbench/ui/zoom/ ZoomToCoordinatePlugIn.java

2016-12-29 Thread edgar . soldin
is r5301 better? ..ede

On 29.12.2016 21:02, Michaël Michaud wrote:
> Hi Ede,
> 
> I don't know what you changed, but the plugin has a strange behaviour.
> 
> When the dialog is get from the menu, clicking on OK just reset the 
> coordinates without zooming to it.
> 
> When the dialog is get from the status bar, it works as usually.
> 
> Michaël
> 
> 
> Le 29/12/2016 à 18:33, jump-pilot-...@lists.sourceforge.net a écrit :
>> Revision: 5296
>>http://sourceforge.net/p/jump-pilot/code/5296
>> Author:   edso
>> Date: 2016-12-29 17:33:41 + (Thu, 29 Dec 2016)
>> Log Message:
>> ---
>> reformat
>> removed unneeded undo call
>>
>> Modified Paths:
>> --
>>  
>> core/trunk/src/com/vividsolutions/jump/workbench/ui/zoom/ZoomToCoordinatePlugIn.java
>>
>> Modified: 
>> core/trunk/src/com/vividsolutions/jump/workbench/ui/zoom/ZoomToCoordinatePlugIn.java
>> ===
>> --- 
>> core/trunk/src/com/vividsolutions/jump/workbench/ui/zoom/ZoomToCoordinatePlugIn.java
>>  2016-12-29 17:32:49 UTC (rev 5295)
>> +++ 
>> core/trunk/src/com/vividsolutions/jump/workbench/ui/zoom/ZoomToCoordinatePlugIn.java
>>  2016-12-29 17:33:41 UTC (rev 5296)
>> @@ -24,96 +24,96 @@
>>   import com.vividsolutions.jump.workbench.ui.cursortool.Animations;
>>   
>>   public class ZoomToCoordinatePlugIn extends AbstractPlugIn {
>> -private Coordinate lastCoordinate = new Coordinate(0, 0);
>> -public boolean execute(PlugInContext context) throws Exception {
>> -reportNothingToUndoYet(context);
>> -Coordinate coordinate = prompt(context);
>> -if (coordinate == null) {
>> -return false;
>> -}
>> -lastCoordinate = coordinate;
>> -context.getLayerViewPanel().getViewport()
>> -.zoom(toEnvelope(coordinate, 
>> context.getLayerManager()));
>> - 
>> Animations.drawExpandingRing(context.getLayerViewPanel().getViewport()
>> -.toViewPoint(lastCoordinate), false, Color.BLUE,
>> -context.getLayerViewPanel(), new float[] { 20, 20 });
>> +  private Coordinate lastCoordinate = new Coordinate(0, 0);
>>   
>> -return true;
>> -}
>> +  public boolean execute(PlugInContext context) throws Exception {
>> +Coordinate coordinate = prompt(context);
>> +if (coordinate == null) {
>> +  return false;
>> +}
>> +lastCoordinate = coordinate;
>> +context.getLayerViewPanel().getViewport()
>> +.zoom(toEnvelope(coordinate, context.getLayerManager()));
>> +Animations.drawExpandingRing(context.getLayerViewPanel().getViewport()
>> +.toViewPoint(lastCoordinate), false, Color.BLUE,
>> +context.getLayerViewPanel(), new float[] { 20, 20 });
>>   
>> -private Coordinate prompt(PlugInContext context) {
>> -while (true) {
>> -try {
>> -return 
>> toCoordinate(JOptionPane.showInputDialog(context
>> -.getWorkbenchFrame(),
>> -
>> I18N.get("ui.zoom.ZoomToCoordinatePlugIn.enter-coordinate-to-zoom-to"), 
>> lastCoordinate.x + ", "
>> -+ 
>> lastCoordinate.y));
>> -} catch (Exception e) {
>> -
>> JOptionPane.showMessageDialog(context.getWorkbenchFrame(), e
>> -.getMessage(),
>> -
>> context.getWorkbenchFrame().getTitle(),
>> -JOptionPane.ERROR_MESSAGE);
>> -}
>> -}
>> +return true;
>> +  }
>>   
>> -}
>> +  private Coordinate prompt(PlugInContext context) {
>> +while (true) {
>> +  try {
>> +return toCoordinate(JOptionPane.showInputDialog(context
>> +.getWorkbenchFrame(), I18N
>> +
>> .get("ui.zoom.ZoomToCoordinatePlugIn.enter-coordinate-to-zoom-to"),
>> +lastCoordinate.x + ", " + lastCoordinate.y));
>> +  } catch (Exception e) {
>> +JOptionPane.showMessageDialog(context.getWorkbenchFrame(),
>> +e.getMessage(), context.getWorkbenchFrame().getTitle(),
>> +JOptionPane.ERROR_MESSAGE);
>> +  }
>> +}
>>   
>> -private Envelope toEnvelope(Coordinate coordinate, LayerManager 
>> layerManager) {
>> -int segments = 0;
>> -int segmentSum = 0;
>> -outer : for (Iterator i = layerManager.iterator(); i.hasNext(); 
>> ) {
>> -Layer layer = (Layer) i.next();
>> -for (Iterator j = 
>> layer.getFeatureCollectionWrapper().iterator(); j
>> -.hasNext(); ) {
>> -Feature feature = (Feature) j.next();
>> -

Re: [JPP-Devel] Transformation in OpenJump ...

2016-12-29 Thread Michaël Michaud
Hi Manfred,

What do you mean exactly ?

In CTS, one performs transformations between two CRS (Coordinate 
Reference System)

A CRS uses a specific datum, ellipsoid, prime meridian, and in case of a 
projected CRS, projection.
With all these informations, it can compute transformations from/to 
WGS84 (geographic or cartesian).

What do you mean by geographic transformation ? How do you define WGS84 
to MGI(Austria) transformation in other softwares ?

Note that all parameters used by cts are in the epsg file (which is the 
same as the one used by proj4).

Michaël



Le 29/12/2016 à 20:03, manf...@egger-gis.at a écrit :
> Hi,
>
> I will held my presenation about OpenJump and transformation in German, but i 
> plan to write a summary for your WIKI in English. There are some not German 
> speaking people there.
>
> One important question about the Transformation Plugin by 
> https://github.com/orbisgis/cts:
>
> Some days ago i transformed coordinates between two datums (WGS 84 to 
> MGI(Austria)). The transformation was ok. But i was suprised that it is not 
> necessary to select a geographic transformation.
>
> In other software you have to select a geographic transformation to get a 
> correct transformation.
>
> What is the reason?
>
> Best regards
>
> Manfred
>
>
>
>
>
> --
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, SlashDot.org! http://sdm.link/slashdot
> ___
> Jump-pilot-devel mailing list
> Jump-pilot-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel
>


--
Check out the vibrant tech community on one of the world's most 
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
___
Jump-pilot-devel mailing list
Jump-pilot-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel


Re: [JPP-Devel] SVN: [5296] core/trunk/src/com/vividsolutions/jump/workbench/ui/zoom/ ZoomToCoordinatePlugIn.java

2016-12-29 Thread Michaël Michaud
Ya seems to be fixed ;-)

Michaël


Le 29/12/2016 à 21:15, edgar.sol...@web.de a écrit :
> is r5301 better? ..ede
>
> On 29.12.2016 21:02, Michaël Michaud wrote:
>> Hi Ede,
>>
>> I don't know what you changed, but the plugin has a strange behaviour.
>>
>> When the dialog is get from the menu, clicking on OK just reset the
>> coordinates without zooming to it.
>>
>> When the dialog is get from the status bar, it works as usually.
>>
>> Michaël
>>
>>
>> Le 29/12/2016 à 18:33, jump-pilot-...@lists.sourceforge.net a écrit :
>>> Revision: 5296
>>> http://sourceforge.net/p/jump-pilot/code/5296
>>> Author:   edso
>>> Date: 2016-12-29 17:33:41 + (Thu, 29 Dec 2016)
>>> Log Message:
>>> ---
>>> reformat
>>> removed unneeded undo call
>>>
>>> Modified Paths:
>>> --
>>>   
>>> core/trunk/src/com/vividsolutions/jump/workbench/ui/zoom/ZoomToCoordinatePlugIn.java
>>>
>>> Modified: 
>>> core/trunk/src/com/vividsolutions/jump/workbench/ui/zoom/ZoomToCoordinatePlugIn.java
>>> ===
>>> --- 
>>> core/trunk/src/com/vividsolutions/jump/workbench/ui/zoom/ZoomToCoordinatePlugIn.java
>>> 2016-12-29 17:32:49 UTC (rev 5295)
>>> +++ 
>>> core/trunk/src/com/vividsolutions/jump/workbench/ui/zoom/ZoomToCoordinatePlugIn.java
>>> 2016-12-29 17:33:41 UTC (rev 5296)
>>> @@ -24,96 +24,96 @@
>>>import com.vividsolutions.jump.workbench.ui.cursortool.Animations;
>>>
>>>public class ZoomToCoordinatePlugIn extends AbstractPlugIn {
>>> -   private Coordinate lastCoordinate = new Coordinate(0, 0);
>>> -   public boolean execute(PlugInContext context) throws Exception {
>>> -   reportNothingToUndoYet(context);
>>> -   Coordinate coordinate = prompt(context);
>>> -   if (coordinate == null) {
>>> -   return false;
>>> -   }
>>> -lastCoordinate = coordinate;
>>> -   context.getLayerViewPanel().getViewport()
>>> -   .zoom(toEnvelope(coordinate, 
>>> context.getLayerManager()));
>>> -
>>> Animations.drawExpandingRing(context.getLayerViewPanel().getViewport()
>>> -   .toViewPoint(lastCoordinate), false, Color.BLUE,
>>> -   context.getLayerViewPanel(), new float[] { 20, 20 });
>>> +  private Coordinate lastCoordinate = new Coordinate(0, 0);
>>>
>>> -   return true;
>>> -   }
>>> +  public boolean execute(PlugInContext context) throws Exception {
>>> +Coordinate coordinate = prompt(context);
>>> +if (coordinate == null) {
>>> +  return false;
>>> +}
>>> +lastCoordinate = coordinate;
>>> +context.getLayerViewPanel().getViewport()
>>> +.zoom(toEnvelope(coordinate, context.getLayerManager()));
>>> +Animations.drawExpandingRing(context.getLayerViewPanel().getViewport()
>>> +.toViewPoint(lastCoordinate), false, Color.BLUE,
>>> +context.getLayerViewPanel(), new float[] { 20, 20 });
>>>
>>> -   private Coordinate prompt(PlugInContext context) {
>>> -   while (true) {
>>> -   try {
>>> -   return 
>>> toCoordinate(JOptionPane.showInputDialog(context
>>> -   .getWorkbenchFrame(),
>>> -   
>>> I18N.get("ui.zoom.ZoomToCoordinatePlugIn.enter-coordinate-to-zoom-to"), 
>>> lastCoordinate.x + ", "
>>> -   + 
>>> lastCoordinate.y));
>>> -   } catch (Exception e) {
>>> -   
>>> JOptionPane.showMessageDialog(context.getWorkbenchFrame(), e
>>> -   .getMessage(),
>>> -   
>>> context.getWorkbenchFrame().getTitle(),
>>> -   JOptionPane.ERROR_MESSAGE);
>>> -   }
>>> -   }
>>> +return true;
>>> +  }
>>>
>>> -   }
>>> +  private Coordinate prompt(PlugInContext context) {
>>> +while (true) {
>>> +  try {
>>> +return toCoordinate(JOptionPane.showInputDialog(context
>>> +.getWorkbenchFrame(), I18N
>>> +
>>> .get("ui.zoom.ZoomToCoordinatePlugIn.enter-coordinate-to-zoom-to"),
>>> +lastCoordinate.x + ", " + lastCoordinate.y));
>>> +  } catch (Exception e) {
>>> +JOptionPane.showMessageDialog(context.getWorkbenchFrame(),
>>> +e.getMessage(), context.getWorkbenchFrame().getTitle(),
>>> +JOptionPane.ERROR_MESSAGE);
>>> +  }
>>> +}
>>>
>>> -   private Envelope toEnvelope(Coordinate coordinate, LayerManager 
>>> layerManager) {
>>> -   int segments = 0;
>>> -   int segmentSum = 0;
>>> -   outer : for (Iterator i = layerManager.iterator(); i.hasNext(); 
>>> ) {
>>> -   Layer layer = (Layer) i.next();
>>> -   for (Iterator j = 
>>> layer.getFeatureCo

[JPP-Devel] SVN: [5302] core/trunk/src/com/vividsolutions/jump/workbench/ui/ WorkbenchFrame.java

2016-12-29 Thread jump-pilot-svn
Revision: 5302
  http://sourceforge.net/p/jump-pilot/code/5302
Author:   edso
Date: 2016-12-29 22:27:57 + (Thu, 29 Dec 2016)
Log Message:
---
partly solve  bug 421, for the statusbar
  https://sourceforge.net/p/jump-pilot/bugs/421/ 

Modified Paths:
--
core/trunk/src/com/vividsolutions/jump/workbench/ui/WorkbenchFrame.java

Modified: 
core/trunk/src/com/vividsolutions/jump/workbench/ui/WorkbenchFrame.java
===
--- core/trunk/src/com/vividsolutions/jump/workbench/ui/WorkbenchFrame.java 
2016-12-29 20:15:00 UTC (rev 5301)
+++ core/trunk/src/com/vividsolutions/jump/workbench/ui/WorkbenchFrame.java 
2016-12-29 22:27:57 UTC (rev 5302)
@@ -229,6 +229,8 @@
 private JPanel statusPanel;
 private JTextArea messageText;
 private JLabel timeLabel, memoryLabel, scaleLabel, coordinateLabel;
+private DecimalFormat scaleFormat = new DecimalFormat("#,###");
+private DecimalFormat scaleFormatSmall = new DecimalFormat("#.");
 private ZoomToScalePlugIn zoomToScalePlugin = new ZoomToScalePlugIn();
 private ZoomToCoordinatePlugIn zoomToCoordPlugin = new 
ZoomToCoordinatePlugIn();
 
@@ -1305,10 +1307,10 @@
 toolBar.updateEnabledState();
 // May be null during a new project initialization
 if (getActiveTaskFrame() != null) {
-setScaleText("1:"
-+ (int) Math.floor(ScreenScale
-.getHorizontalMapScale(getActiveTaskFrame()
-.getLayerViewPanel().getViewport(;
+  double scale = ScreenScale.getHorizontalMapScale(getActiveTaskFrame()
+  .getLayerViewPanel().getViewport());
+  DecimalFormat format = scale >= 10 ? scaleFormat : scaleFormatSmall;
+  setScaleText("1:" + format.format(scale));
 }
 }
 


--
Check out the vibrant tech community on one of the world's most 
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
___
Jump-pilot-devel mailing list
Jump-pilot-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel


[JPP-Devel] SVN: [5303] core/trunk/src/com/vividsolutions/jump/util/StringUtil.java

2016-12-29 Thread jump-pilot-svn
Revision: 5303
  http://sourceforge.net/p/jump-pilot/code/5303
Author:   edso
Date: 2016-12-30 00:45:46 + (Fri, 30 Dec 2016)
Log Message:
---
added utility function

Modified Paths:
--
core/trunk/src/com/vividsolutions/jump/util/StringUtil.java

Modified: core/trunk/src/com/vividsolutions/jump/util/StringUtil.java
===
--- core/trunk/src/com/vividsolutions/jump/util/StringUtil.java 2016-12-29 
22:27:57 UTC (rev 5302)
+++ core/trunk/src/com/vividsolutions/jump/util/StringUtil.java 2016-12-30 
00:45:46 UTC (rev 5303)
@@ -373,4 +373,28 @@
 
 return buf.toString();
 }
+
+/**
+ * format Doubles to String representation, cutting zeroes from the 
decimal end
+ * eg. 1234.000 -> "1234", 1234.5600 -> "1234.56"
+ * @param d
+ * @return string
+ */
+public static String toString(double d) {
+  if (d == (long) d)
+return String.format("%d", (long) d);
+  else {
+// detect number of decimal digits (until there are only zeroes)
+int i = 1;
+for (; i <= 12; i++) {
+  double factor = (double) Math.pow(10, i);
+  double temp = ((long) (d * factor)) / factor;
+  System.out.println(temp);
+  if (temp == d)
+break;
+}
+System.out.println("orig:" + d);
+return String.format("%." + i + "f", d);
+  }
+}
 }


--
Check out the vibrant tech community on one of the world's most 
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
___
Jump-pilot-devel mailing list
Jump-pilot-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel


[JPP-Devel] SVN: [5304] core/trunk/src/com/vividsolutions/jump/util/StringUtil.java

2016-12-29 Thread jump-pilot-svn
Revision: 5304
  http://sourceforge.net/p/jump-pilot/code/5304
Author:   edso
Date: 2016-12-30 00:58:41 + (Fri, 30 Dec 2016)
Log Message:
---
refined utility function

Modified Paths:
--
core/trunk/src/com/vividsolutions/jump/util/StringUtil.java

Modified: core/trunk/src/com/vividsolutions/jump/util/StringUtil.java
===
--- core/trunk/src/com/vividsolutions/jump/util/StringUtil.java 2016-12-30 
00:45:46 UTC (rev 5303)
+++ core/trunk/src/com/vividsolutions/jump/util/StringUtil.java 2016-12-30 
00:58:41 UTC (rev 5304)
@@ -389,12 +389,11 @@
 for (; i <= 12; i++) {
   double factor = (double) Math.pow(10, i);
   double temp = ((long) (d * factor)) / factor;
-  System.out.println(temp);
   if (temp == d)
-break;
+return String.format("%." + i + "f", d);
 }
-System.out.println("orig:" + d);
-return String.format("%." + i + "f", d);
+// eventually we simply return the double
+return Double.toString(d);
   }
 }
 }


--
Check out the vibrant tech community on one of the world's most 
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
___
Jump-pilot-devel mailing list
Jump-pilot-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel


[JPP-Devel] Transformation in OpenJump ...

2016-12-29 Thread manf...@egger-gis.at
Hi Michael,

Look at the attached file. In ArcGis 10.3.1 you have to select a geographic 
transformation before you start a transformation between two datums.

It seems that the transformation in CTS does not need such a information?

And if i want to transform from MGI (Austria) to 
D_Deutsches_Hauptdreiecksnetz(Germany)? Does this run automatically too?

Transformation from MGI to WGS 84 and after that transformation from WGS84 to 
D_Deutsches_Hauptdreiecksnetz?

Best regards,

Manfred



Hi Manfred,

What do you mean exactly ?

In CTS, one performs transformations between two CRS (Coordinate 
Reference System)

A CRS uses a specific datum, ellipsoid, prime meridian, and in case of a 
projected CRS, projection.
With all these informations, it can compute transformations from/to 
WGS84 (geographic or cartesian).

What do you mean by geographic transformation ? How do you define WGS84 
to MGI(Austria) transformation in other softwares ?

Note that all parameters used by cts are in the epsg file (which is the 
same as the one used by proj4).

Micha?l



Le 29/12/2016 ? 20:03, manf...@egger-gis.at a ?crit :
> Hi,
>
> I will held my presenation about OpenJump and transformation in German, but i 
> plan to write a summary for your WIKI in English. There are some not German 
> speaking people there.
>
> One important question about the Transformation Plugin by 
> https://github.com/orbisgis/cts:
>
> Some days ago i transformed coordinates between two datums (WGS 84 to 
> MGI(Austria)). The transformation was ok. But i was suprised that it is not 
> necessary to select a geographic transformation.
>
> In other software you have to select a geographic transformation to get a 
> correct transformation.
>
> What is the reason?
>
> Best regards
>
> Manfred
>
>
>
>
>
> --
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, SlashDot.org! http://sdm.link/slashdot
> ___
> Jump-pilot-devel mailing list
> Jump-pilot-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel
>




--

Message: 4
Date: Thu, 29 Dec 2016 21:23:21 +0100
From: Micha?l Michaud 
Subject: Re: [JPP-Devel] SVN: [5296]
core/trunk/src/com/vividsolutions/jump/workbench/ui/zoom/
ZoomToCoordinatePlugIn.java
To: jump-pilot-devel@lists.sourceforge.net
Message-ID: 
Content-Type: text/plain; charset=windows-1252; format=flowed

Ya seems to be fixed ;-)

Micha?l


Le 29/12/2016 ? 21:15, edgar.sol...@web.de a ?crit :
> is r5301 better? ..ede
>
> On 29.12.2016 21:02, Micha?l Michaud wrote:
>> Hi Ede,
>>
>> I don't know what you changed, but the plugin has a strange behaviour.
>>
>> When the dialog is get from the menu, clicking on OK just reset the
>> coordinates without zooming to it.
>>
>> When the dialog is get from the status bar, it works as usually.
>>
>> Micha?l
>>
>>
>> Le 29/12/2016 ? 18:33, jump-pilot-...@lists.sourceforge.net a ?crit :
>>> Revision: 5296
>>> http://sourceforge.net/p/jump-pilot/code/5296
>>> Author:   edso
>>> Date: 2016-12-29 17:33:41 + (Thu, 29 Dec 2016)
>>> Log Message:
>>> ---
>>> reformat
>>> removed unneeded undo call
>>>
>>> Modified Paths:
>>> --
>>>   
>>> core/trunk/src/com/vividsolutions/jump/workbench/ui/zoom/ZoomToCoordinatePlugIn.java
>>>
>>> Modified: 
>>> core/trunk/src/com/vividsolutions/jump/workbench/ui/zoom/ZoomToCoordinatePlugIn.java
>>> ===
>>> --- 
>>> core/trunk/src/com/vividsolutions/jump/workbench/ui/zoom/ZoomToCoordinatePlugIn.java
>>> 2016-12-29 17:32:49 UTC (rev 5295)
>>> +++ 
>>> core/trunk/src/com/vividsolutions/jump/workbench/ui/zoom/ZoomToCoordinatePlugIn.java
>>> 2016-12-29 17:33:41 UTC (rev 5296)
>>> @@ -24,96 +24,96 @@
>>>import com.vividsolutions.jump.workbench.ui.cursortool.Animations;
>>>
>>>public class ZoomToCoordinatePlugIn extends AbstractPlugIn {
>>> -   private Coordinate lastCoordinate = new Coordinate(0, 0);
>>> -   public boolean execute(PlugInContext context) throws Exception {
>>> -   reportNothingToUndoYet(context);
>>> -   Coordinate coordinate = prompt(context);
>>> -   if (coordinate == null) {
>>> -   return false;
>>> -   }
>>> -lastCoordinate = coordinate;
>>> -   context.getLayerViewPanel().getViewport()
>>> -   .zoom(toEnvelope(coordinate, 
>>> context.getLayerManager()));
>>> -
>>> Animations.drawExpandingRing(context.getLayerViewPanel().getViewport()
>>> -   .toViewPoint(lastCoordinate), false, Color.BLUE,
>>> -   context.getLayerViewPanel(), new float[] { 20, 20 });
>>> +  private Coordinate lastCoordinate = new Coordinate(0, 0);
>>>
>>> -   return true;
>>> -   }
>>> +  public