Index: /applications/editors/josm/plugins/public_transport/src/public_transport/GTFSAddCommand.java
===================================================================
--- /applications/editors/josm/plugins/public_transport/src/public_transport/GTFSAddCommand.java	(revision 26167)
+++ /applications/editors/josm/plugins/public_transport/src/public_transport/GTFSAddCommand.java	(revision 26168)
@@ -1,3 +1,5 @@
 package public_transport;
+
+import static org.openstreetmap.josm.tools.I18n.tr;
 
 import org.openstreetmap.josm.Main;
@@ -57,5 +59,5 @@
          (String)gtfsStopTM.getValueAt(j, 1));
       gtfsStopTM.nodes.set(j, node);
-      gtfsStopTM.setValueAt("added", j, 2);
+      gtfsStopTM.setValueAt(tr("added"), j, 2);
     }
     return true;
@@ -85,5 +87,5 @@
   @Override public JLabel getDescription()
   {
-    return new JLabel("public_transport.GTFSStops.Enable");
+    return new JLabel(tr("Public Transport: Enable GTFSStops"));
   }
 };
Index: /applications/editors/josm/plugins/public_transport/src/public_transport/GTFSCatchCommand.java
===================================================================
--- /applications/editors/josm/plugins/public_transport/src/public_transport/GTFSCatchCommand.java	(revision 26167)
+++ /applications/editors/josm/plugins/public_transport/src/public_transport/GTFSCatchCommand.java	(revision 26168)
@@ -1,3 +1,5 @@
 package public_transport;
+
+import static org.openstreetmap.josm.tools.I18n.tr;
 
 import org.openstreetmap.josm.Main;
@@ -108,5 +110,5 @@
   @Override public JLabel getDescription()
   {
-    return new JLabel("public_transport.GTFSStops.Catch");
+    return new JLabel(tr("Public Transport: Catch GTFS stops"));
   }
 };
Index: /applications/editors/josm/plugins/public_transport/src/public_transport/GTFSDeleteCommand.java
===================================================================
--- /applications/editors/josm/plugins/public_transport/src/public_transport/GTFSDeleteCommand.java	(revision 26167)
+++ /applications/editors/josm/plugins/public_transport/src/public_transport/GTFSDeleteCommand.java	(revision 26168)
@@ -1,3 +1,5 @@
 package public_transport;
+
+import static org.openstreetmap.josm.tools.I18n.tr;
 
 import org.openstreetmap.josm.Main;
@@ -59,5 +61,5 @@
     continue;
       gtfsStopTM.nodes.set(j, null);
-      gtfsStopTM.setValueAt("skipped", j, 2);
+      gtfsStopTM.setValueAt(tr("skipped"), j, 2);
       Main.main.getCurrentDataSet().removePrimitive(node);
       node.setDeleted(true);
@@ -89,5 +91,5 @@
   @Override public JLabel getDescription()
   {
-    return new JLabel("public_transport.GTFS.Disable");
+    return new JLabel(tr("Public Transport: Disable GTFS"));
   }
 };
Index: /applications/editors/josm/plugins/public_transport/src/public_transport/GTFSImporterAction.java
===================================================================
--- /applications/editors/josm/plugins/public_transport/src/public_transport/GTFSImporterAction.java	(revision 26167)
+++ /applications/editors/josm/plugins/public_transport/src/public_transport/GTFSImporterAction.java	(revision 26168)
@@ -1,5 +1,4 @@
 package public_transport;
 
-import static org.openstreetmap.josm.tools.I18n.marktr;
 import static org.openstreetmap.josm.tools.I18n.tr;
 
@@ -115,16 +114,16 @@
       if (curDir.equals(""))
       {
-    curDir = ".";
+        curDir = ".";
       }
       JFileChooser fc = new JFileChooser(new File(curDir));
-      fc.setDialogTitle("Select GTFS file (stops.txt)");
+      fc.setDialogTitle(tr("Select GTFS file (stops.txt)"));
       fc.setMultiSelectionEnabled(false);
 
       int answer = fc.showOpenDialog(Main.parent);
       if (answer != JFileChooser.APPROVE_OPTION)
-    return;
+        return;
 
       if (!fc.getCurrentDirectory().getAbsolutePath().equals(curDir))
-    Main.pref.put("lastDirectory", fc.getCurrentDirectory().getAbsolutePath());
+        Main.pref.put("lastDirectory", fc.getCurrentDirectory().getAbsolutePath());
 
       importData(fc.getSelectedFile());
@@ -216,9 +215,7 @@
       if (Main.main.getCurrentDataSet() == null)
       {
-        JOptionPane.showMessageDialog(null, "There exists no dataset."
-        + " Try to download data from the server or open an OSM file.",
-     "No data found", JOptionPane.ERROR_MESSAGE);
-
-        System.out.println("Public Transport: StopInserter: No data found");
+        JOptionPane.showMessageDialog(null, tr("There exists no dataset."
+        + " Try to download data from the server or open an OSM file."),
+        tr("No data found"), JOptionPane.ERROR_MESSAGE);
 
         return;
@@ -226,24 +223,22 @@
       else
       {
-    Iterator< Node > iter =
+        Iterator< Node > iter =
         Main.main.getCurrentDataSet().getNodes().iterator();
-    while (iter.hasNext())
-    {
-      Node node = iter.next();
-      if ("bus_stop".equals(node.get("highway")))
-        existingStops.add(node);
-    }
+        while (iter.hasNext())
+        {
+          Node node = iter.next();
+          if ("bus_stop".equals(node.get("highway")))
+            existingStops.add(node);
+        }
       }
 
       Iterator< String > iter = data.iterator();
       if (iter.hasNext())
-    gtfsStopTM = new GTFSStopTableModel(this, iter.next());
+        gtfsStopTM = new GTFSStopTableModel(this, iter.next());
       else
       {
-    JOptionPane.showMessageDialog
-    (null, "The GTFS file was empty.", "No data found",
-     JOptionPane.ERROR_MESSAGE);
-
-        System.out.println("Public Transport: GTFSImporter: No data found");
+        JOptionPane.showMessageDialog
+        (null, tr("The GTFS file was empty."), tr("No data found"),
+        JOptionPane.ERROR_MESSAGE);
 
         return;
@@ -252,6 +247,6 @@
       while (iter.hasNext())
       {
-    String s = iter.next();
-    gtfsStopTM.addRow(s, existingStops);
+        String s = iter.next();
+        gtfsStopTM.addRow(s, existingStops);
       }
       dialog.setGTFSStopTableModel(gtfsStopTM);
@@ -260,8 +255,6 @@
     {
       JOptionPane.showMessageDialog
-      (null, "The GTFS file was empty.", "No data found",
+      (null, tr("The GTFS file was empty."), tr("No data found"),
        JOptionPane.ERROR_MESSAGE);
-
-      System.out.println("Public Transport: GTFSImporter: No data found");
     }
   }
@@ -298,9 +291,7 @@
     if (Main.main.getCurrentDataSet() == null)
     {
-      JOptionPane.showMessageDialog(null, "There exists no dataset."
-      + " Try to download data from the server or open an OSM file.",
-   "No data found", JOptionPane.ERROR_MESSAGE);
-
-      System.out.println("Public Transport: StopInserter: No data found");
+      JOptionPane.showMessageDialog(null, tr("There exists no dataset."
+      + " Try to download data from the server or open an OSM file."),
+      tr("No data found"), JOptionPane.ERROR_MESSAGE);
 
       return null;
@@ -319,10 +310,10 @@
     {
       for (int i = 0; i < selectedLines.length; ++i)
-    consideredLines.add(selectedLines[i]);
+        consideredLines.add(selectedLines[i]);
     }
     else
     {
       for (int i = 0; i < table.getRowCount(); ++i)
-    consideredLines.add(new Integer(i));
+        consideredLines.add(new Integer(i));
     }
     return consideredLines;
@@ -340,6 +331,6 @@
     {
       if ((nodes.elementAt(i) != null) &&
-       (Main.main.getCurrentDataSet().isSelected(nodes.elementAt(i))))
-    table.addRowSelectionInterval(i, i);
+      (Main.main.getCurrentDataSet().isSelected(nodes.elementAt(i))))
+        table.addRowSelectionInterval(i, i);
     }
   }
@@ -355,5 +346,5 @@
       int j = consideredLines.elementAt(i);
       if (nodes.elementAt(j) != null)
-    nodes.elementAt(j).visit(box);
+        nodes.elementAt(j).visit(box);
     }
     if (box.getBounds() == null)
@@ -374,5 +365,5 @@
       int j = consideredLines.elementAt(i);
       if (nodes.elementAt(j) != null)
-    Main.main.getCurrentDataSet().addSelected(nodes.elementAt(j));
+        Main.main.getCurrentDataSet().addSelected(nodes.elementAt(j));
     }
   }
Index: /applications/editors/josm/plugins/public_transport/src/public_transport/GTFSImporterDialog.java
===================================================================
--- /applications/editors/josm/plugins/public_transport/src/public_transport/GTFSImporterDialog.java	(revision 26167)
+++ /applications/editors/josm/plugins/public_transport/src/public_transport/GTFSImporterDialog.java	(revision 26168)
@@ -74,14 +74,15 @@
   private JTable stoplistTable = null;
   private JTable gtfsStopTable = null;
+  private final String[] stoptypes = new String[]{marktr("bus"), marktr("tram"), marktr("light_rail"), marktr("subway"), marktr("rail")};
 
   public GTFSImporterDialog(GTFSImporterAction controller)
   {
     Frame frame = JOptionPane.getFrameForComponent(Main.parent);
-    jDialog = new JDialog(frame, "Create Stops from GTFS", false);
+    jDialog = new JDialog(frame, tr("Create Stops from GTFS"), false);
     tabbedPane = new JTabbedPane();
     JPanel tabSettings = new JPanel();
-    tabbedPane.addTab(marktr("Settings"), tabSettings);
+    tabbedPane.addTab(tr("Settings"), tabSettings);
     JPanel tabWaypoints = new JPanel();
-    tabbedPane.addTab(marktr("GTFS-Stops"), tabWaypoints);
+    tabbedPane.addTab(tr("GTFS-Stops"), tabWaypoints);
     tabbedPane.setEnabledAt(0, false);
     tabbedPane.setEnabledAt(1, true);
@@ -94,5 +95,5 @@
     contentPane.setLayout(gridbag);
 
-    JLabel label = new JLabel("Type of stops to add");
+    JLabel label = new JLabel(tr("Type of stops to add"));
 
     layoutCons.gridx = 0;
@@ -107,9 +108,6 @@
     cbStoptype = new JComboBox();
     cbStoptype.setEditable(false);
-    cbStoptype.addItem("bus");
-    cbStoptype.addItem("tram");
-    cbStoptype.addItem("light_rail");
-    cbStoptype.addItem("subway");
-    cbStoptype.addItem("rail");
+    for(String type : stoptypes)
+        cbStoptype.addItem(new TransText(type));
     cbStoptype.setActionCommand("gtfsImporter.settingsStoptype");
     cbStoptype.addActionListener(controller);
@@ -124,5 +122,5 @@
     contentPane.add(cbStoptype);
 
-    label = new JLabel("Time on your GPS device");
+    label = new JLabel(tr("Time on your GPS device"));
 
     layoutCons.gridx = 0;
@@ -148,5 +146,6 @@
     contentPane.add(tfGPSTimeStart);
 
-    label = new JLabel("HH:MM:SS.sss");
+    /* I18n: Don't change the time format, you only may translate the letters */
+    label = new JLabel(tr("HH:MM:SS.sss"));
 
     layoutCons.gridx = 1;
@@ -159,5 +158,5 @@
     contentPane.add(label);
 
-    label = new JLabel("Time on your stopwatch");
+    label = new JLabel(tr("Time on your stopwatch"));
 
     layoutCons.gridx = 0;
@@ -183,5 +182,6 @@
     contentPane.add(tfStopwatchStart);
 
-    label = new JLabel("HH:MM:SS.sss");
+    /* I18n: Don't change the time format, you only may translate the letters */
+    label = new JLabel(tr("HH:MM:SS.sss"));
 
     layoutCons.gridx = 1;
@@ -194,5 +194,5 @@
     contentPane.add(label);
 
-    label = new JLabel("Time window");
+    label = new JLabel(tr("Time window"));
 
     layoutCons.gridx = 0;
@@ -218,5 +218,5 @@
     contentPane.add(tfTimeWindow);
 
-    label = new JLabel("seconds");
+    label = new JLabel(tr("seconds"));
 
     layoutCons.gridx = 1;
@@ -229,5 +229,5 @@
     contentPane.add(label);
 
-    label = new JLabel("Move Threshold");
+    label = new JLabel(tr("Move Threshold"));
 
     layoutCons.gridx = 0;
@@ -253,5 +253,5 @@
     contentPane.add(tfThreshold);
 
-    label = new JLabel("meters");
+    label = new JLabel(tr("meters"));
 
     layoutCons.gridx = 1;
@@ -264,5 +264,5 @@
     contentPane.add(label);
 
-    JButton bSuggestStops = new JButton("Suggest Stops");
+    JButton bSuggestStops = new JButton(tr("Suggest Stops"));
     bSuggestStops.setActionCommand("gtfsImporter.settingsSuggestStops");
     bSuggestStops.addActionListener(controller);
@@ -319,5 +319,5 @@
     contentPane.add(tableSP);
 
-    JButton bFind = new JButton("Find");
+    JButton bFind = new JButton(tr("Find"));
     bFind.setActionCommand("gtfsImporter.gtfsStopsFind");
     bFind.addActionListener(controller);
@@ -332,5 +332,5 @@
     contentPane.add(bFind);
 
-    JButton bShow = new JButton("Show");
+    JButton bShow = new JButton(tr("Show"));
     bShow.setActionCommand("gtfsImporter.gtfsStopsShow");
     bShow.addActionListener(controller);
@@ -345,5 +345,5 @@
     contentPane.add(bShow);
 
-    JButton bMark = new JButton("Mark");
+    JButton bMark = new JButton(tr("Mark"));
     bMark.setActionCommand("gtfsImporter.gtfsStopsMark");
     bMark.addActionListener(controller);
@@ -359,5 +359,5 @@
     contentPane.add(bMark);
 
-    JButton bCatch = new JButton("Catch");
+    JButton bCatch = new JButton(tr("Catch"));
     bCatch.setActionCommand("gtfsImporter.gtfsStopsCatch");
     bCatch.addActionListener(controller);
@@ -373,5 +373,5 @@
     contentPane.add(bCatch);
 
-    JButton bJoin = new JButton("Join");
+    JButton bJoin = new JButton(tr("Join"));
     bJoin.setActionCommand("gtfsImporter.gtfsStopsJoin");
     bJoin.addActionListener(controller);
@@ -387,5 +387,5 @@
     contentPane.add(bJoin);
 
-    JButton bAdd = new JButton("Enable");
+    JButton bAdd = new JButton(tr("Enable"));
     bAdd.setActionCommand("gtfsImporter.gtfsStopsAdd");
     bAdd.addActionListener(controller);
@@ -401,5 +401,5 @@
     contentPane.add(bAdd);
 
-    JButton bDelete = new JButton("Disable");
+    JButton bDelete = new JButton(tr("Disable"));
     bDelete.setActionCommand("gtfsImporter.gtfsStopsDelete");
     bDelete.addActionListener(controller);
@@ -440,5 +440,5 @@
   public String getStoptype()
   {
-    return (String)cbStoptype.getSelectedItem();
+    return ((TransText)cbStoptype.getSelectedItem()).text;
   }
 
@@ -452,5 +452,5 @@
     {
       JOptionPane.showMessageDialog
-      (null, "Can't parse a time from this string.", "Invalid value",
+      (null, tr("Can't parse a time from this string."), tr("Invalid value"),
        JOptionPane.ERROR_MESSAGE);
       return false;
@@ -477,5 +477,5 @@
     {
       JOptionPane.showMessageDialog
-      (null, "Can't parse a time from this string.", "Invalid value",
+      (null, tr("Can't parse a time from this string."), tr("Invalid value"),
        JOptionPane.ERROR_MESSAGE);
       return false;
Index: /applications/editors/josm/plugins/public_transport/src/public_transport/GTFSJoinCommand.java
===================================================================
--- /applications/editors/josm/plugins/public_transport/src/public_transport/GTFSJoinCommand.java	(revision 26167)
+++ /applications/editors/josm/plugins/public_transport/src/public_transport/GTFSJoinCommand.java	(revision 26168)
@@ -1,3 +1,5 @@
 package public_transport;
+
+import static org.openstreetmap.josm.tools.I18n.tr;
 
 import org.openstreetmap.josm.Main;
@@ -66,5 +68,5 @@
     gtfsStopTM.nodes.set(j, dest);
     type = (String)gtfsStopTM.getValueAt(j, 2);
-    gtfsStopTM.setValueAt("moved", j, 2);
+    gtfsStopTM.setValueAt(tr("moved"), j, 2);
 
     return true;
@@ -106,5 +108,5 @@
   @Override public JLabel getDescription()
   {
-    return new JLabel("public_transport.GTFSStops.Join");
+    return new JLabel(tr("Public Transport: Join GTFS stops"));
   }
 };
Index: /applications/editors/josm/plugins/public_transport/src/public_transport/GTFSStopTableModel.java
===================================================================
--- /applications/editors/josm/plugins/public_transport/src/public_transport/GTFSStopTableModel.java	(revision 26167)
+++ /applications/editors/josm/plugins/public_transport/src/public_transport/GTFSStopTableModel.java	(revision 26168)
@@ -1,5 +1,4 @@
 package public_transport;
 
-import static org.openstreetmap.josm.tools.I18n.marktr;
 import static org.openstreetmap.josm.tools.I18n.tr;
 
@@ -70,7 +69,7 @@
 
     this.controller = controller;
-    addColumn("Id");
-    addColumn("Name");
-    addColumn("State");
+    addColumn(tr("Id"));
+    addColumn(tr("Name"));
+    addColumn(tr("State"));
     addTableModelListener(this);
   }
@@ -138,5 +137,5 @@
   public void insertRow(int insPos, String s, Vector< Node > existingStops)
   {
-    String[] buf = { "", "", "pending" };
+    String[] buf = { "", "", tr("pending") };
     int pos = tokenize(s, 0);
     int oldPos = 0;
@@ -176,12 +175,12 @@
       while (iter.hasNext())
       {
-    if (iter.next().bounds.contains(coor))
-    {
-      inside = true;
-      break;
-    }
+        if (iter.next().bounds.contains(coor))
+        {
+          inside = true;
+          break;
+        }
       }
       if (!inside)
-    buf[2] = "outside";
+        buf[2] = tr("outside");
     }
 
@@ -193,6 +192,6 @@
       if (coor.greatCircleDistance(node.getCoor()) < 1000)
       {
-    nearBusStop = true;
-    break;
+        nearBusStop = true;
+        break;
       }
     }
@@ -200,11 +199,11 @@
     if (insPos == -1)
     {
-      if ((nearBusStop) || !("pending".equals(buf[2])))
-    nodes.addElement(null);
+      if ((nearBusStop) || !(tr("pending").equals(buf[2])))
+        nodes.addElement(null);
       else
       {
-    Node node = GTFSImporterAction.createNode(coor, buf[0], buf[1]);
-    nodes.addElement(node);
-    buf[2] = "added";
+        Node node = GTFSImporterAction.createNode(coor, buf[0], buf[1]);
+        nodes.addElement(node);
+        buf[2] = tr("added");
       }
       coors.addElement(coor);
@@ -213,11 +212,11 @@
     else
     {
-      if ((nearBusStop) || !("pending".equals(buf[2])))
-    nodes.insertElementAt(null, insPos);
+      if ((nearBusStop) || !(tr("pending").equals(buf[2])))
+        nodes.insertElementAt(null, insPos);
       else
       {
-    Node node = GTFSImporterAction.createNode(coor, buf[0], buf[1]);
-    nodes.insertElementAt(node, insPos);
-    buf[2] = "added";
+        Node node = GTFSImporterAction.createNode(coor, buf[0], buf[1]);
+        nodes.insertElementAt(node, insPos);
+        buf[2] = tr("added");
       }
       coors.insertElementAt(coor, insPos);
Index: /applications/editors/josm/plugins/public_transport/src/public_transport/ItineraryTableModel.java
===================================================================
--- /applications/editors/josm/plugins/public_transport/src/public_transport/ItineraryTableModel.java	(revision 26167)
+++ /applications/editors/josm/plugins/public_transport/src/public_transport/ItineraryTableModel.java	(revision 26168)
@@ -1,61 +1,14 @@
 package public_transport;
 
-// import static org.openstreetmap.josm.tools.I18n.marktr;
-// import static org.openstreetmap.josm.tools.I18n.tr;
-//
-// import java.awt.BorderLayout;
-// import java.awt.Container;
-// import java.awt.Dimension;
-// import java.awt.Frame;
-// import java.awt.GridBagConstraints;
-// import java.awt.GridBagLayout;
-// import java.awt.event.ActionEvent;
-// import java.util.Collection;
-// import java.util.Collections;
-// import java.util.Iterator;
-// import java.util.LinkedList;
-// import java.util.List;
-// import java.util.ListIterator;
-// import java.util.Map;
-// import java.util.TreeMap;
-// import java.util.TreeSet;
+import static org.openstreetmap.josm.tools.I18n.tr;
+
 import java.util.Vector;
-//
-// import javax.swing.DefaultCellEditor;
-// import javax.swing.DefaultListModel;
-// import javax.swing.JButton;
-// import javax.swing.JCheckBox;
-// import javax.swing.JComboBox;
-// import javax.swing.JDialog;
-// import javax.swing.JLabel;
-// import javax.swing.JList;
-// import javax.swing.JOptionPane;
-// import javax.swing.JPanel;
-// import javax.swing.JScrollPane;
-// import javax.swing.JTabbedPane;
-// import javax.swing.JTable;
-// import javax.swing.JTextField;
-// import javax.swing.ListSelectionModel;
-// import javax.swing.event.ListSelectionEvent;
-// import javax.swing.event.ListSelectionListener;
+
 import javax.swing.event.TableModelEvent;
 import javax.swing.event.TableModelListener;
 import javax.swing.table.DefaultTableModel;
-// import javax.swing.table.TableCellEditor;
-//
-// import org.openstreetmap.josm.Main;
-// import org.openstreetmap.josm.actions.JosmAction;
-// import org.openstreetmap.josm.actions.mapmode.DeleteAction;
-// import org.openstreetmap.josm.data.osm.DataSet;
+
 import org.openstreetmap.josm.data.osm.Node;
-// import org.openstreetmap.josm.data.osm.OsmPrimitive;
-// import org.openstreetmap.josm.data.osm.Relation;
-// import org.openstreetmap.josm.data.osm.RelationMember;
 import org.openstreetmap.josm.data.osm.Way;
-// import org.openstreetmap.josm.data.osm.visitor.BoundingXYVisitor;
-// import org.openstreetmap.josm.gui.ExtendedDialog;
-// import org.openstreetmap.josm.tools.GBC;
-// import org.openstreetmap.josm.tools.Shortcut;
-// import org.openstreetmap.josm.tools.UrlLabel;
 
 public class ItineraryTableModel extends DefaultTableModel
@@ -104,11 +57,11 @@
     String curName = way.get("name");
     if (way.isIncomplete())
-      buf[0] = "[incomplete]";
+      buf[0] = tr("[incomplete]");
     else if (way.getNodesCount() < 1)
-      buf[0] = "[empty way]";
+      buf[0] = tr("[empty way]");
     else if (curName != null)
       buf[0] = curName;
     else
-      buf[0] = "[ID] " + (new Long(way.getId())).toString();
+      buf[0] = tr("[ID] {0}", (new Long(way.getId())).toString());
     buf[1] = role;
     if (insPos == -1)
@@ -139,18 +92,18 @@
       if (ways.elementAt(i) == null)
       {
-    ++i;
-    if (i >= getRowCount())
-      break;
+        ++i;
+        if (i >= getRowCount())
+          break;
       }
       while ((ways.elementAt(i) == null) &&
-    ((i == 0) || (ways.elementAt(i-1) == null)))
+      ((i == 0) || (ways.elementAt(i-1) == null)))
       {
-    ways.removeElementAt(i);
-    removeRow(i);
-    if (i >= getRowCount())
-      break;
+        ways.removeElementAt(i);
+        removeRow(i);
+        if (i >= getRowCount())
+          break;
       }
       if (i >= getRowCount())
-    break;
+        break;
 
       boolean gapRequired = gapNecessary
@@ -158,14 +111,14 @@
       if ((i > 0) && (!gapRequired) && (ways.elementAt(i-1) == null))
       {
-    ways.removeElementAt(i-1);
-    removeRow(i-1);
-    --i;
+        ways.removeElementAt(i-1);
+        removeRow(i-1);
+        --i;
       }
       else if ((i > 0) && gapRequired && (ways.elementAt(i-1) != null))
       {
-    String[] buf = { "", "" };
-    buf[0] = "[gap]";
-    insertRow(i, buf);
-    ++i;
+        String[] buf = { "", "" };
+        buf[0] = tr("[gap]");
+        insertRow(i, buf);
+        ++i;
       }
       lastNode = getLastNode(ways.elementAt(i), (String)(getValueAt(i, 1)));
@@ -185,5 +138,5 @@
     {
       if (inEvent)
-    return;
+        return;
       cleanupGaps();
       RoutePatternAction.rebuildWays();
@@ -198,7 +151,7 @@
     {
       if ("backward".equals(role))
-      return way.getNode(0);
+        return way.getNode(0);
       else
-    return way.getNode(way.getNodesCount() - 1);
+        return way.getNode(way.getNodesCount() - 1);
     }
   }
@@ -210,9 +163,9 @@
       Node firstNode = null;
       if ("backward".equals(role))
-      firstNode = way.getNode(way.getNodesCount() - 1);
+        firstNode = way.getNode(way.getNodesCount() - 1);
       else
-    firstNode = way.getNode(0);
+        firstNode = way.getNode(0);
       if ((lastNode != null) && (!lastNode.equals(firstNode)))
-    return true;
+        return true;
     }
     return false;
Index: /applications/editors/josm/plugins/public_transport/src/public_transport/PublicTransportPlugin.java
===================================================================
--- /applications/editors/josm/plugins/public_transport/src/public_transport/PublicTransportPlugin.java	(revision 26167)
+++ /applications/editors/josm/plugins/public_transport/src/public_transport/PublicTransportPlugin.java	(revision 26168)
@@ -2,5 +2,4 @@
 
 import static org.openstreetmap.josm.tools.I18n.marktr;
-import static org.openstreetmap.josm.tools.I18n.tr;
 
 import java.awt.event.KeyEvent;
Index: /applications/editors/josm/plugins/public_transport/src/public_transport/RoutePatternAction.java
===================================================================
--- /applications/editors/josm/plugins/public_transport/src/public_transport/RoutePatternAction.java	(revision 26167)
+++ /applications/editors/josm/plugins/public_transport/src/public_transport/RoutePatternAction.java	(revision 26168)
@@ -85,46 +85,46 @@
       if (route.get("route") != null)
       {
-    if (rr.route.get("route") == null)
-      return -1;
-    int result = route.get("route").compareTo(rr.route.get("route"));
-    if (result != 0)
+        if (rr.route.get("route") == null)
+          return -1;
+        int result = route.get("route").compareTo(rr.route.get("route"));
+        if (result != 0)
+          return result;
+      }
+      else if (rr.route.get("route") != null)
+        return 1;
+      if (route.get("ref") != null)
+      {
+        if (rr.route.get("ref") == null)
+          return -1;
+        int result = route.get("ref").compareTo(rr.route.get("ref"));
+        if (result != 0)
       return result;
       }
-      else if (rr.route.get("route") != null)
-    return 1;
-      if (route.get("ref") != null)
-      {
-    if (rr.route.get("ref") == null)
-      return -1;
-    int result = route.get("ref").compareTo(rr.route.get("ref"));
-    if (result != 0)
-      return result;
-      }
       else if (rr.route.get("ref") != null)
-    return 1;
+        return 1;
       if (route.get("to") != null)
       {
-    if (rr.route.get("to") == null)
-      return -1;
-    int result = route.get("to").compareTo(rr.route.get("to"));
-    if (result != 0)
-      return result;
+        if (rr.route.get("to") == null)
+          return -1;
+        int result = route.get("to").compareTo(rr.route.get("to"));
+        if (result != 0)
+          return result;
       }
       else if (rr.route.get("to") != null)
-    return 1;
+        return 1;
       if (route.get("direction") != null)
       {
-    if (rr.route.get("direction") == null)
-      return -1;
-    int result = route.get("direction").compareTo(rr.route.get("direction"));
-    if (result != 0)
-      return result;
+        if (rr.route.get("direction") == null)
+          return -1;
+        int result = route.get("direction").compareTo(rr.route.get("direction"));
+        if (result != 0)
+          return result;
       }
       else if (rr.route.get("direction") != null)
-    return 1;
+        return 1;
       if (route.getId() < rr.route.getId())
-    return -1;
+        return -1;
       else if (route.getId() > rr.route.getId())
-    return 1;
+        return 1;
       return 0;
     }
@@ -134,18 +134,18 @@
       if ((route.get("ref") != null) && (route.get("ref") != ""))
       {
-    if ((route.get("to") != null) && (route.get("to") != ""))
-    {
-      buf += " " + route.get("ref") + ": " + route.get("to");
-    }
-    else if ((route.get("direction") != null) && (route.get("direction") != ""))
-    {
-      buf += " " + route.get("ref") + ": " + route.get("direction");
-    }
-    else
-    {
-      buf += " " + route.get("ref");
-    }
-      }
-      buf += " [ID " + Long.toString(route.getId()) + "]";
+        if ((route.get("to") != null) && (route.get("to") != ""))
+        {
+          buf += " " + route.get("ref") + ": " + route.get("to");
+        }
+        else if ((route.get("direction") != null) && (route.get("direction") != ""))
+        {
+          buf += " " + route.get("ref") + ": " + route.get("direction");
+        }
+        else
+        {
+          buf += " " + route.get("ref");
+        }
+      }
+      buf += tr(" [ID] {0}", Long.toString(route.getId()));
 
       return buf;
@@ -164,5 +164,5 @@
     public boolean isCellEditable(int row, int column) {
       if ((column == 0) && (hasFixedKeys))
-    return false;
+        return false;
       return true;
     }
@@ -173,8 +173,8 @@
       for (int i = 0; i < getRowCount(); ++i)
       {
-    String value = rel.get((String)getValueAt(i, 0));
-    if (value == null)
-      value = "";
-    setValueAt(value, i, 1);
+        String value = rel.get((String)getValueAt(i, 0));
+        if (value == null)
+          value = "";
+        setValueAt(value, i, 1);
       }
     }
@@ -188,20 +188,20 @@
       while (iter.hasNext())
       {
-    Map.Entry< String, String > entry = iter.next();
-    if (!blacklist.contains(entry.getKey()))
-    {
-      Vector< String > newRow = new Vector< String >();
-      newRow.add(entry.getKey());
-      newRow.add(entry.getValue());
-      addRow(newRow);
-    }
+        Map.Entry< String, String > entry = iter.next();
+        if (!blacklist.contains(entry.getKey()))
+        {
+          Vector< String > newRow = new Vector< String >();
+          newRow.add(entry.getKey());
+          newRow.add(entry.getValue());
+          addRow(newRow);
+        }
       }
 
       for (int i = 0; i < getRowCount(); ++i)
       {
-    String value = rel.get((String)getValueAt(i, 0));
-    if (value == null)
-      value = "";
-    setValueAt(value, i, 1);
+        String value = rel.get((String)getValueAt(i, 0));
+        if (value == null)
+          value = "";
+        setValueAt(value, i, 1);
       }
     }
@@ -211,22 +211,22 @@
       if (e.getType() == TableModelEvent.UPDATE)
       {
-    relation.setModified(true);
-
-    String key = (String)getValueAt(e.getFirstRow(), 0);
-    if (key == null)
-      return;
-    if ((blacklist == null) || (!blacklist.contains(key)))
-    {
-      relation.setModified(true);
-      if ("".equals(getValueAt(e.getFirstRow(), 1)))
-        relation.remove(key);
-      else
-        relation.put(key, (String)getValueAt(e.getFirstRow(), 1));
-    }
-    else
-    {
-      if (e.getColumn() == 0)
-        setValueAt("", e.getFirstRow(), 0);
-    }
+        relation.setModified(true);
+
+        String key = (String)getValueAt(e.getFirstRow(), 0);
+        if (key == null)
+          return;
+        if ((blacklist == null) || (!blacklist.contains(key)))
+        {
+          relation.setModified(true);
+          if ("".equals(getValueAt(e.getFirstRow(), 1)))
+            relation.remove(key);
+          else
+            relation.put(key, (String)getValueAt(e.getFirstRow(), 1));
+        }
+        else
+        {
+          if (e.getColumn() == 0)
+            setValueAt("", e.getFirstRow(), 0);
+        }
       }
     }
@@ -245,18 +245,18 @@
       TableCellEditor editor = null;
       if (column == 0)
-    editor = col1.get(new Integer(row));
+        editor = col1.get(new Integer(row));
       else
-    editor = col2.get(new Integer(row));
+        editor = col2.get(new Integer(row));
       if (editor == null)
-    return new DefaultCellEditor(new JTextField());
+        return new DefaultCellEditor(new JTextField());
       else
-    return editor;
+        return editor;
     }
 
     public void setCellEditor(int row, int column, TableCellEditor editor) {
       if (column == 0)
-    col1.put(new Integer(row), editor);
+        col1.put(new Integer(row), editor);
       else
-    col2.put(new Integer(row), editor);
+        col2.put(new Integer(row), editor);
     }
   };
@@ -293,5 +293,5 @@
       else
       {
-        buf[0] = "[ID] " + (new Long(node.getId())).toString();
+        buf[0] = tr("[ID] {0}", (new Long(node.getId())).toString());
       }
       String curRef = node.get("ref");
@@ -325,5 +325,5 @@
       if (e.getType() == TableModelEvent.UPDATE)
       {
-    rebuildNodes();
+        rebuildNodes();
       }
     }
@@ -427,16 +427,16 @@
     if (jDialog == null)
     {
-      jDialog = new JDialog(frame, "Route Patterns", false);
+      jDialog = new JDialog(frame, tr("Route Patterns"), false);
       tabbedPane = new JTabbedPane();
       JPanel tabOverview = new JPanel();
-      tabbedPane.addTab(marktr("Overview"), tabOverview);
+      tabbedPane.addTab(tr("Overview"), tabOverview);
       JPanel tabTags = new JPanel();
-      tabbedPane.addTab(marktr("Tags"), tabTags);
+      tabbedPane.addTab(tr("Tags"), tabTags);
       JPanel tabItinerary = new JPanel();
-      tabbedPane.addTab(marktr("Itinerary"), tabItinerary);
+      tabbedPane.addTab(tr("Itinerary"), tabItinerary);
       JPanel tabStoplist = new JPanel();
-      tabbedPane.addTab(marktr("Stops"), tabStoplist);
+      tabbedPane.addTab(tr("Stops"), tabStoplist);
       JPanel tabMeta = new JPanel();
-      tabbedPane.addTab(marktr("Meta"), tabMeta);
+      tabbedPane.addTab(tr("Meta"), tabMeta);
       tabbedPane.setEnabledAt(0, true);
       tabbedPane.setEnabledAt(1, false);
@@ -452,5 +452,5 @@
       contentPane.setLayout(gridbag);
 
-      JLabel headline = new JLabel("Existing route patterns:");
+      JLabel headline = new JLabel(tr("Existing route patterns:"));
 
       layoutCons.gridx = 0;
@@ -480,5 +480,5 @@
       contentPane.add(rpListSP);
 
-      JButton bRefresh = new JButton("Refresh");
+      JButton bRefresh = new JButton(tr("Refresh"));
       bRefresh.setActionCommand("routePattern.refresh");
       bRefresh.addActionListener(this);
@@ -494,5 +494,5 @@
       contentPane.add(bRefresh);
 
-      JButton bNew = new JButton("New");
+      JButton bNew = new JButton(tr("New"));
       bNew.setActionCommand("routePattern.overviewNew");
       bNew.addActionListener(this);
@@ -508,5 +508,5 @@
       contentPane.add(bNew);
 
-      JButton bDelete = new JButton("Delete");
+      JButton bDelete = new JButton(tr("Delete"));
       bDelete.setActionCommand("routePattern.overviewDelete");
       bDelete.addActionListener(this);
@@ -522,5 +522,5 @@
       contentPane.add(bDelete);
 
-      JButton bDuplicate = new JButton("Duplicate");
+      JButton bDuplicate = new JButton(tr("Duplicate"));
       bDuplicate.setActionCommand("routePattern.overviewDuplicate");
       bDuplicate.addActionListener(this);
@@ -536,5 +536,5 @@
       contentPane.add(bDuplicate);
 
-      JButton bReflect = new JButton("Reflect");
+      JButton bReflect = new JButton(tr("Reflect"));
       bReflect.setActionCommand("routePattern.overviewReflect");
       bReflect.addActionListener(this);
@@ -556,5 +556,5 @@
       contentPane.setLayout(gridbag);
 
-      /*JLabel*/ headline = new JLabel("Required tags:");
+      /*JLabel*/ headline = new JLabel(tr("Required tags:"));
 
       layoutCons.gridx = 0;
@@ -568,8 +568,9 @@
       requiredTagsTable = new CustomCellEditorTable();
       requiredTagsData = new TagTableModel(true);
-      requiredTagsData.addColumn("Key");
-      requiredTagsData.addColumn("Value");
+      requiredTagsData.addColumn(tr("Key"));
+      requiredTagsData.addColumn(tr("Value"));
       tagBlacklist = new TreeSet< String >();
       Vector< String > rowContent = new Vector< String >();
+      /* TODO: keys and values should also be translated using TransText class */
       rowContent.add("type");
       tagBlacklist.add("type");
@@ -622,5 +623,5 @@
       contentPane.add(tableSP);
 
-      headline = new JLabel("Common tags:");
+      headline = new JLabel(tr("Common tags:"));
 
       layoutCons.gridx = 0;
@@ -634,6 +635,6 @@
       commonTagsTable = new CustomCellEditorTable();
       commonTagsData = new TagTableModel(true);
-      commonTagsData.addColumn("Key");
-      commonTagsData.addColumn("Value");
+      commonTagsData.addColumn(tr("Key"));
+      commonTagsData.addColumn(tr("Value"));
       rowContent = new Vector< String >();
       rowContent.add(0, "direction");
@@ -676,5 +677,5 @@
       contentPane.add(tableSP);
 
-      headline = new JLabel("Additional tags:");
+      headline = new JLabel(tr("Additional tags:"));
 
       layoutCons.gridx = 0;
@@ -688,6 +689,6 @@
       otherTagsTable = new CustomCellEditorTable();
       otherTagsData = new TagTableModel(false);
-      otherTagsData.addColumn("Key");
-      otherTagsData.addColumn("Value");
+      otherTagsData.addColumn(tr("Key"));
+      otherTagsData.addColumn(tr("Value"));
       otherTagsTable.setModel(otherTagsData);
       /*JScrollPane*/ tableSP = new JScrollPane(otherTagsTable);
@@ -705,5 +706,5 @@
       contentPane.add(tableSP);
 
-      JButton bAddTag = new JButton("Add a new Tag");
+      JButton bAddTag = new JButton(tr("Add a new Tag"));
       bAddTag.setActionCommand("routePattern.tagAddTag");
       bAddTag.addActionListener(this);
@@ -726,6 +727,6 @@
       itineraryTable = new JTable();
       itineraryData = new ItineraryTableModel();
-      itineraryData.addColumn("Name/Id");
-      itineraryData.addColumn("Role");
+      itineraryData.addColumn(tr("Name/Id"));
+      itineraryData.addColumn(tr("Role"));
       itineraryTable.setModel(itineraryData);
       /*JScrollPane*/ tableSP = new JScrollPane(itineraryTable);
@@ -747,5 +748,5 @@
       contentPane.add(tableSP);
 
-      JButton bFind = new JButton("Find");
+      JButton bFind = new JButton(tr("Find"));
       bFind.setActionCommand("routePattern.itineraryFind");
       bFind.addActionListener(this);
@@ -760,5 +761,5 @@
       contentPane.add(bFind);
 
-      JButton bShow = new JButton("Show");
+      JButton bShow = new JButton(tr("Show"));
       bShow.setActionCommand("routePattern.itineraryShow");
       bShow.addActionListener(this);
@@ -773,5 +774,5 @@
       contentPane.add(bShow);
 
-      JButton bMark = new JButton("Mark");
+      JButton bMark = new JButton(tr("Mark"));
       bMark.setActionCommand("routePattern.itineraryMark");
       bMark.addActionListener(this);
@@ -787,5 +788,5 @@
       contentPane.add(bMark);
 
-      JButton bAdd = new JButton("Add");
+      JButton bAdd = new JButton(tr("Add"));
       bAdd.setActionCommand("routePattern.itineraryAdd");
       bAdd.addActionListener(this);
@@ -801,5 +802,5 @@
       contentPane.add(bAdd);
 
-      /*JButton*/ bDelete = new JButton("Delete");
+      /*JButton*/ bDelete = new JButton(tr("Delete"));
       bDelete.setActionCommand("routePattern.itineraryDelete");
       bDelete.addActionListener(this);
@@ -814,5 +815,5 @@
       contentPane.add(bDelete);
 
-      JButton bSort = new JButton("Sort");
+      JButton bSort = new JButton(tr("Sort"));
       bSort.setActionCommand("routePattern.itinerarySort");
       bSort.addActionListener(this);
@@ -827,5 +828,5 @@
       contentPane.add(bSort);
 
-      /*JButton*/ bReflect = new JButton("Reflect");
+      /*JButton*/ bReflect = new JButton(tr("Reflect"));
       bReflect.setActionCommand("routePattern.itineraryReflect");
       bReflect.addActionListener(this);
@@ -848,7 +849,7 @@
       stoplistTable = new JTable();
       stoplistData = new StoplistTableModel();
-      stoplistData.addColumn("Name/Id");
-      stoplistData.addColumn("Ref");
-      stoplistData.addColumn("Role");
+      stoplistData.addColumn(tr("Name/Id"));
+      stoplistData.addColumn(tr("Ref"));
+      stoplistData.addColumn(tr("Role"));
       stoplistTable.setModel(stoplistData);
       /*JScrollPane*/ tableSP = new JScrollPane(stoplistTable);
@@ -870,5 +871,5 @@
       contentPane.add(tableSP);
 
-      /*JButton*/ bFind = new JButton("Find");
+      /*JButton*/ bFind = new JButton(tr("Find"));
       bFind.setActionCommand("routePattern.stoplistFind");
       bFind.addActionListener(this);
@@ -883,5 +884,5 @@
       contentPane.add(bFind);
 
-      /*JButton*/ bShow = new JButton("Show");
+      /*JButton*/ bShow = new JButton(tr("Show"));
       bShow.setActionCommand("routePattern.stoplistShow");
       bShow.addActionListener(this);
@@ -896,5 +897,5 @@
       contentPane.add(bShow);
 
-      /*JButton*/ bMark = new JButton("Mark");
+      /*JButton*/ bMark = new JButton(tr("Mark"));
       bMark.setActionCommand("routePattern.stoplistMark");
       bMark.addActionListener(this);
@@ -910,5 +911,5 @@
       contentPane.add(bMark);
 
-      /*JButton*/ bAdd = new JButton("Add");
+      /*JButton*/ bAdd = new JButton(tr("Add"));
       bAdd.setActionCommand("routePattern.stoplistAdd");
       bAdd.addActionListener(this);
@@ -924,5 +925,5 @@
       contentPane.add(bAdd);
 
-      /*JButton*/ bDelete = new JButton("Delete");
+      /*JButton*/ bDelete = new JButton(tr("Delete"));
       bDelete.setActionCommand("routePattern.stoplistDelete");
       bDelete.addActionListener(this);
@@ -937,5 +938,5 @@
       contentPane.add(bDelete);
 
-      /*JButton*/ bSort = new JButton("Sort");
+      /*JButton*/ bSort = new JButton(tr("Sort"));
       bSort.setActionCommand("routePattern.stoplistSort");
       bSort.addActionListener(this);
@@ -950,5 +951,5 @@
       contentPane.add(bSort);
 
-      /*JButton*/ bReflect = new JButton("Reflect");
+      /*JButton*/ bReflect = new JButton(tr("Reflect"));
       bReflect.setActionCommand("routePattern.stoplistReflect");
       bReflect.addActionListener(this);
@@ -969,5 +970,5 @@
       contentPane.setLayout(gridbag);
 
-      JLabel rightleft = new JLabel("Stops are possible on the");
+      JLabel rightleft = new JLabel(tr("Stops are possible on the"));
 
       layoutCons.gridx = 0;
@@ -980,5 +981,5 @@
       contentPane.add(rightleft);
 
-      cbRight = new JCheckBox("right hand side", true);
+      cbRight = new JCheckBox(tr("right hand side"), true);
 
       layoutCons.gridx = 0;
@@ -991,5 +992,5 @@
       contentPane.add(cbRight);
 
-      cbLeft = new JCheckBox("left hand side", false);
+      cbLeft = new JCheckBox(tr("left hand side"), false);
 
       layoutCons.gridx = 0;
@@ -1002,5 +1003,5 @@
       contentPane.add(cbLeft);
 
-      JLabel maxdist = new JLabel("Maximum distance from route");
+      JLabel maxdist = new JLabel(tr("Maximum distance from route"));
 
       layoutCons.gridx = 0;
@@ -1024,5 +1025,5 @@
       contentPane.add(tfSuggestStopsLimit);
 
-      JLabel meters = new JLabel("meters");
+      JLabel meters = new JLabel(tr("meters"));
 
       layoutCons.gridx = 1;
@@ -1035,5 +1036,5 @@
       contentPane.add(meters);
 
-      JButton bSuggestStops = new JButton("Suggest Stops");
+      JButton bSuggestStops = new JButton(tr("Suggest Stops"));
       bSuggestStops.setActionCommand("routePattern.metaSuggestStops");
       bSuggestStops.addActionListener(this);
@@ -1099,29 +1100,29 @@
       for (int i = 0; i < currentRoute.getMembersCount(); ++i)
       {
-    RelationMember item = currentRoute.getMember(i);
-
-    if (item.isWay())
-    {
-      String role = item.getRole();
-      if ("backward".equals(role))
-        role = "forward";
-      else if ("forward".equals(role))
-        role = "backward";
-      else
-        role = "backward";
-
-      itemsToReflect.add(new RelationMember(role, item.getWay()));
-    }
-    else if (item.isNode())
-      itemsToReflect.add(item);
-    else
-      otherItems.add(item);
+        RelationMember item = currentRoute.getMember(i);
+
+        if (item.isWay())
+        {
+          String role = item.getRole();
+          if ("backward".equals(role))
+            role = "forward";
+          else if ("forward".equals(role))
+            role = "backward";
+          else
+            role = "backward";
+
+          itemsToReflect.add(new RelationMember(role, item.getWay()));
+        }
+        else if (item.isNode())
+          itemsToReflect.add(item);
+        else
+          otherItems.add(item);
       }
 
       currentRoute.setMembers(null);
       for (int i = itemsToReflect.size()-1; i >= 0; --i)
-    currentRoute.addMember(itemsToReflect.elementAt(i));
+        currentRoute.addMember(itemsToReflect.elementAt(i));
       for (int i = 0; i < otherItems.size(); ++i)
-    currentRoute.addMember(otherItems.elementAt(i));
+        currentRoute.addMember(otherItems.elementAt(i));
 
       refreshData();
@@ -1129,6 +1130,6 @@
       for (int i = 0; i < relsListModel.size(); ++i)
       {
-    if (currentRoute == ((RouteReference)relsListModel.elementAt(i)).route)
-      relsList.setSelectedIndex(i);
+        if (currentRoute == ((RouteReference)relsListModel.elementAt(i)).route)
+          relsList.setSelectedIndex(i);
       }
     }
@@ -1155,5 +1156,5 @@
     {
       if (mainDataSet == null)
-    return;
+        return;
 
       itineraryTable.clearSelection();
@@ -1161,7 +1162,7 @@
       for (int i = 0; i < itineraryData.getRowCount(); ++i)
       {
-    if ((itineraryData.ways.elementAt(i) != null) &&
-        (mainDataSet.isSelected(itineraryData.ways.elementAt(i))))
-        itineraryTable.addRowSelectionInterval(i, i);
+        if ((itineraryData.ways.elementAt(i) != null) &&
+            (mainDataSet.isSelected(itineraryData.ways.elementAt(i))))
+            itineraryTable.addRowSelectionInterval(i, i);
       }
     }
@@ -1171,24 +1172,24 @@
       if (itineraryTable.getSelectedRowCount() > 0)
       {
-    for (int i = 0; i < itineraryData.getRowCount(); ++i)
-    {
-      if ((itineraryTable.isRowSelected(i)) && (itineraryData.ways.elementAt(i) != null))
-      {
-        itineraryData.ways.elementAt(i).visit(box);
-      }
-    }
+        for (int i = 0; i < itineraryData.getRowCount(); ++i)
+        {
+          if ((itineraryTable.isRowSelected(i)) && (itineraryData.ways.elementAt(i) != null))
+          {
+            itineraryData.ways.elementAt(i).visit(box);
+          }
+        }
       }
       else
       {
-    for (int i = 0; i < itineraryData.getRowCount(); ++i)
-    {
-      if (itineraryData.ways.elementAt(i) != null)
-      {
-        itineraryData.ways.elementAt(i).visit(box);
-      }
-    }
+        for (int i = 0; i < itineraryData.getRowCount(); ++i)
+        {
+          if (itineraryData.ways.elementAt(i) != null)
+          {
+            itineraryData.ways.elementAt(i).visit(box);
+          }
+        }
       }
       if (box.getBounds() == null)
-    return;
+        return;
       box.enlargeBoundingBox();
       Main.map.mapView.recalculateCenterScale(box);
@@ -1201,29 +1202,29 @@
       if (itineraryTable.getSelectedRowCount() > 0)
       {
-    for (int i = 0; i < itineraryData.getRowCount(); ++i)
-    {
-      if ((itineraryTable.isRowSelected(i)) && (itineraryData.ways.elementAt(i) != null))
-      {
-        mainDataSet.addSelected(itineraryData.ways.elementAt(i));
-
-        RelationMember markedWay = new RelationMember
-        ((String)(itineraryData.getValueAt(i, 1)), itineraryData.ways.elementAt(i));
-        markedWays.addElement(markedWay);
-      }
-    }
+        for (int i = 0; i < itineraryData.getRowCount(); ++i)
+        {
+          if ((itineraryTable.isRowSelected(i)) && (itineraryData.ways.elementAt(i) != null))
+          {
+            mainDataSet.addSelected(itineraryData.ways.elementAt(i));
+
+            RelationMember markedWay = new RelationMember
+            ((String)(itineraryData.getValueAt(i, 1)), itineraryData.ways.elementAt(i));
+            markedWays.addElement(markedWay);
+          }
+        }
       }
       else
       {
-    for (int i = 0; i < itineraryData.getRowCount(); ++i)
-    {
-      if (itineraryData.ways.elementAt(i) != null)
-      {
-        mainDataSet.addSelected(itineraryData.ways.elementAt(i));
-
-        RelationMember markedWay = new RelationMember
-        ((String)(itineraryData.getValueAt(i, 1)), itineraryData.ways.elementAt(i));
-        markedWays.addElement(markedWay);
-      }
-    }
+        for (int i = 0; i < itineraryData.getRowCount(); ++i)
+        {
+          if (itineraryData.ways.elementAt(i) != null)
+          {
+            mainDataSet.addSelected(itineraryData.ways.elementAt(i));
+
+            RelationMember markedWay = new RelationMember
+            ((String)(itineraryData.getValueAt(i, 1)), itineraryData.ways.elementAt(i));
+            markedWays.addElement(markedWay);
+          }
+        }
       }
     }
@@ -1234,17 +1235,17 @@
       TreeSet<Way> addedWays = new TreeSet<Way>();
       if (mainDataSet == null)
-    return;
+        return;
 
       while (relIter.hasNext())
       {
-    RelationMember curMember = relIter.next();
-    if ((curMember.isWay()) && (mainDataSet.isSelected(curMember.getWay())))
-    {
-      itineraryData.insertRow(insPos, curMember.getWay(), curMember.getRole());
-      if (insPos >= 0)
-        ++insPos;
-
-      addedWays.add(curMember.getWay());
-    }
+        RelationMember curMember = relIter.next();
+        if ((curMember.isWay()) && (mainDataSet.isSelected(curMember.getWay())))
+        {
+          itineraryData.insertRow(insPos, curMember.getWay(), curMember.getRole());
+          if (insPos >= 0)
+            ++insPos;
+
+          addedWays.add(curMember.getWay());
+        }
       }
 
@@ -1254,21 +1255,21 @@
       while (wayIter.hasNext())
       {
-    Way curMember = wayIter.next();
-    if (!(addedWays.contains(curMember)))
-    {
-      itineraryData.insertRow(insPos, curMember, "");
-      if (insPos >= 0)
-        ++insPos;
-    }
+        Way curMember = wayIter.next();
+        if (!(addedWays.contains(curMember)))
+        {
+          itineraryData.insertRow(insPos, curMember, "");
+          if (insPos >= 0)
+            ++insPos;
+        }
       }
 
       if ((insPos > 0) && (insPos < itineraryData.getRowCount()))
       {
-    while ((insPos < itineraryData.getRowCount())
-               && (itineraryData.ways.elementAt(insPos) == null))
-      ++insPos;
-    itineraryTable.removeRowSelectionInterval(0, itineraryData.getRowCount()-1);
-    if (insPos < itineraryData.getRowCount())
-      itineraryTable.addRowSelectionInterval(insPos, insPos);
+        while ((insPos < itineraryData.getRowCount())
+                  && (itineraryData.ways.elementAt(insPos) == null))
+          ++insPos;
+        itineraryTable.removeRowSelectionInterval(0, itineraryData.getRowCount()-1);
+        if (insPos < itineraryData.getRowCount())
+          itineraryTable.addRowSelectionInterval(insPos, insPos);
       }
 
@@ -1280,9 +1281,9 @@
       for (int i = itineraryData.getRowCount()-1; i >=0; --i)
       {
-    if ((itineraryTable.isRowSelected(i)) && (itineraryData.ways.elementAt(i) != null))
-    {
-      itineraryData.ways.removeElementAt(i);
-      itineraryData.removeRow(i);
-    }
+        if ((itineraryTable.isRowSelected(i)) && (itineraryData.ways.elementAt(i) != null))
+        {
+          itineraryData.ways.removeElementAt(i);
+          itineraryData.removeRow(i);
+        }
       }
 
@@ -1303,36 +1304,36 @@
       if (itineraryTable.getSelectedRowCount() > 0)
       {
-    for (int i = itineraryData.getRowCount()-1; i >=0; --i)
-    {
-      if ((itineraryTable.isRowSelected(i)) && (itineraryData.ways.elementAt(i) != null))
-      {
-        if (!(usedWays.contains(itineraryData.ways.elementAt(i))))
-        {
-          addWayToSortingData
-          (itineraryData.ways.elementAt(i), frontNodes, backNodes, loops);
-          usedWays.add(itineraryData.ways.elementAt(i));
-        }
-
-        itineraryData.ways.removeElementAt(i);
-        itineraryData.removeRow(i);
-      }
-    }
+        for (int i = itineraryData.getRowCount()-1; i >=0; --i)
+        {
+          if ((itineraryTable.isRowSelected(i)) && (itineraryData.ways.elementAt(i) != null))
+          {
+            if (!(usedWays.contains(itineraryData.ways.elementAt(i))))
+            {
+              addWayToSortingData
+              (itineraryData.ways.elementAt(i), frontNodes, backNodes, loops);
+              usedWays.add(itineraryData.ways.elementAt(i));
+            }
+
+            itineraryData.ways.removeElementAt(i);
+            itineraryData.removeRow(i);
+          }
+        }
       }
       else
       {
-    for (int i = itineraryData.getRowCount()-1; i >=0; --i)
-    {
-      if (itineraryData.ways.elementAt(i) != null)
-      {
-        if (!(usedWays.contains(itineraryData.ways.elementAt(i))))
-        {
-          addWayToSortingData
-          (itineraryData.ways.elementAt(i), frontNodes, backNodes, loops);
-          usedWays.add(itineraryData.ways.elementAt(i));
-        }
-      }
-    }
-
-    itineraryData.clear();
+        for (int i = itineraryData.getRowCount()-1; i >=0; --i)
+        {
+          if (itineraryData.ways.elementAt(i) != null)
+          {
+            if (!(usedWays.contains(itineraryData.ways.elementAt(i))))
+            {
+              addWayToSortingData
+              (itineraryData.ways.elementAt(i), frontNodes, backNodes, loops);
+              usedWays.add(itineraryData.ways.elementAt(i));
+            }
+          }
+        }
+
+        itineraryData.clear();
       }
 
@@ -1341,12 +1342,12 @@
       while (entryIter.hasNext())
       {
-    Iterator<RelationMember> relIter = entryIter.next().getValue().iterator();
-    while (relIter.hasNext())
-    {
-      RelationMember curMember = relIter.next();
-      itineraryData.insertRow(insPos, curMember.getWay(), curMember.getRole());
-      if (insPos >= 0)
-        ++insPos;
-    }
+        Iterator<RelationMember> relIter = entryIter.next().getValue().iterator();
+        while (relIter.hasNext())
+        {
+          RelationMember curMember = relIter.next();
+          itineraryData.insertRow(insPos, curMember.getWay(), curMember.getRole());
+          if (insPos >= 0)
+            ++insPos;
+        }
       }
 
@@ -1354,12 +1355,12 @@
       while (listIter.hasNext())
       {
-    Iterator<RelationMember> relIter = listIter.next().iterator();
-    while (relIter.hasNext())
-    {
-      RelationMember curMember = relIter.next();
-      itineraryData.insertRow(insPos, curMember.getWay(), curMember.getRole());
-      if (insPos >= 0)
-        ++insPos;
-    }
+        Iterator<RelationMember> relIter = listIter.next().iterator();
+        while (relIter.hasNext())
+        {
+          RelationMember curMember = relIter.next();
+          itineraryData.insertRow(insPos, curMember.getWay(), curMember.getRole());
+          if (insPos >= 0)
+            ++insPos;
+        }
       }
 
@@ -1374,44 +1375,44 @@
       if (itineraryTable.getSelectedRowCount() > 0)
       {
-    for (int i = itineraryData.getRowCount()-1; i >=0; --i)
-    {
-      if ((itineraryTable.isRowSelected(i)) && (itineraryData.ways.elementAt(i) != null))
-      {
-        String role = (String)(itineraryData.getValueAt(i, 1));
-        if ("backward".equals(role))
-          role = "forward";
-        else if ("forward".equals(role))
-          role = "backward";
-        else
-          role = "backward";
-        RelationMember markedWay = new RelationMember
-        (role, itineraryData.ways.elementAt(i));
-        itemsToReflect.addElement(markedWay);
-
-        itineraryData.ways.removeElementAt(i);
-        itineraryData.removeRow(i);
-      }
-    }
+        for (int i = itineraryData.getRowCount()-1; i >=0; --i)
+        {
+          if ((itineraryTable.isRowSelected(i)) && (itineraryData.ways.elementAt(i) != null))
+          {
+            String role = (String)(itineraryData.getValueAt(i, 1));
+            if ("backward".equals(role))
+              role = "forward";
+            else if ("forward".equals(role))
+              role = "backward";
+            else
+              role = "backward";
+            RelationMember markedWay = new RelationMember
+            (role, itineraryData.ways.elementAt(i));
+            itemsToReflect.addElement(markedWay);
+
+            itineraryData.ways.removeElementAt(i);
+            itineraryData.removeRow(i);
+          }
+        }
       }
       else
       {
-    for (int i = itineraryData.getRowCount()-1; i >=0; --i)
-    {
-      if (itineraryData.ways.elementAt(i) != null)
-      {
-        String role = (String)(itineraryData.getValueAt(i, 1));
-        if ("backward".equals(role))
-          role = "forward";
-        else if ("forward".equals(role))
-          role = "backward";
-        else
-          role = "backward";
-        RelationMember markedWay = new RelationMember
-        (role, itineraryData.ways.elementAt(i));
-        itemsToReflect.addElement(markedWay);
-      }
-    }
-
-    itineraryData.clear();
+        for (int i = itineraryData.getRowCount()-1; i >=0; --i)
+        {
+          if (itineraryData.ways.elementAt(i) != null)
+          {
+            String role = (String)(itineraryData.getValueAt(i, 1));
+            if ("backward".equals(role))
+              role = "forward";
+            else if ("forward".equals(role))
+              role = "backward";
+            else
+              role = "backward";
+            RelationMember markedWay = new RelationMember
+            (role, itineraryData.ways.elementAt(i));
+            itemsToReflect.addElement(markedWay);
+          }
+        }
+
+        itineraryData.clear();
       }
 
@@ -1420,14 +1421,14 @@
       while (relIter.hasNext())
       {
-    RelationMember curMember = relIter.next();
-    if (curMember.isWay())
-    {
-      itineraryData.insertRow(insPos, curMember.getWay(), curMember.getRole());
+        RelationMember curMember = relIter.next();
+        if (curMember.isWay())
+        {
+          itineraryData.insertRow(insPos, curMember.getWay(), curMember.getRole());
+          if (insPos >= 0)
+            ++insPos;
+        }
+      }
       if (insPos >= 0)
-        ++insPos;
-    }
-      }
-      if (insPos >= 0)
-    itineraryTable.addRowSelectionInterval(startPos, insPos-1);
+        itineraryTable.addRowSelectionInterval(startPos, insPos-1);
 
       itineraryData.cleanupGaps();
@@ -1437,5 +1438,5 @@
     {
       if (mainDataSet == null)
-    return;
+        return;
 
       stoplistTable.clearSelection();
@@ -1443,7 +1444,7 @@
       for (int i = 0; i < stoplistData.getRowCount(); ++i)
       {
-    if ((stoplistData.nodes.elementAt(i) != null) &&
-          (mainDataSet.isSelected(stoplistData.nodes.elementAt(i))))
-      stoplistTable.addRowSelectionInterval(i, i);
+        if ((stoplistData.nodes.elementAt(i) != null) &&
+              (mainDataSet.isSelected(stoplistData.nodes.elementAt(i))))
+          stoplistTable.addRowSelectionInterval(i, i);
       }
     }
@@ -1453,21 +1454,21 @@
       if (stoplistTable.getSelectedRowCount() > 0)
       {
-    for (int i = 0; i < stoplistData.getRowCount(); ++i)
-    {
-      if (stoplistTable.isRowSelected(i))
-      {
-        stoplistData.nodes.elementAt(i).visit(box);
-      }
-    }
+        for (int i = 0; i < stoplistData.getRowCount(); ++i)
+        {
+          if (stoplistTable.isRowSelected(i))
+          {
+            stoplistData.nodes.elementAt(i).visit(box);
+          }
+        }
       }
       else
       {
-    for (int i = 0; i < stoplistData.getRowCount(); ++i)
-    {
-      stoplistData.nodes.elementAt(i).visit(box);
-    }
+        for (int i = 0; i < stoplistData.getRowCount(); ++i)
+        {
+          stoplistData.nodes.elementAt(i).visit(box);
+        }
       }
       if (box.getBounds() == null)
-    return;
+        return;
       box.enlargeBoundingBox();
       Main.map.mapView.recalculateCenterScale(box);
@@ -1480,26 +1481,26 @@
       if (stoplistTable.getSelectedRowCount() > 0)
       {
-    for (int i = 0; i < stoplistData.getRowCount(); ++i)
-    {
-      if (stoplistTable.isRowSelected(i))
-      {
-        mainDataSet.addSelected(stoplistData.nodes.elementAt(i));
-
-        RelationMember markedNode = new RelationMember
-        ((String)(stoplistData.getValueAt(i, 1)), stoplistData.nodes.elementAt(i));
-        markedNodes.addElement(markedNode);
-      }
-    }
+        for (int i = 0; i < stoplistData.getRowCount(); ++i)
+        {
+          if (stoplistTable.isRowSelected(i))
+          {
+            mainDataSet.addSelected(stoplistData.nodes.elementAt(i));
+
+            RelationMember markedNode = new RelationMember
+            ((String)(stoplistData.getValueAt(i, 1)), stoplistData.nodes.elementAt(i));
+            markedNodes.addElement(markedNode);
+          }
+        }
       }
       else
       {
-    for (int i = 0; i < stoplistData.getRowCount(); ++i)
-    {
-      mainDataSet.addSelected(stoplistData.nodes.elementAt(i));
-
-      RelationMember markedNode = new RelationMember
-          ((String)(stoplistData.getValueAt(i, 1)), stoplistData.nodes.elementAt(i));
-      markedNodes.addElement(markedNode);
-    }
+        for (int i = 0; i < stoplistData.getRowCount(); ++i)
+        {
+          mainDataSet.addSelected(stoplistData.nodes.elementAt(i));
+
+          RelationMember markedNode = new RelationMember
+              ((String)(stoplistData.getValueAt(i, 1)), stoplistData.nodes.elementAt(i));
+          markedNodes.addElement(markedNode);
+        }
       }
     }
@@ -1510,17 +1511,17 @@
       TreeSet<Node> addedNodes = new TreeSet<Node>();
       if (mainDataSet == null)
-    return;
+        return;
 
       while (relIter.hasNext())
       {
-    RelationMember curMember = relIter.next();
-    if ((curMember.isNode()) && (mainDataSet.isSelected(curMember.getNode())))
-    {
-      stoplistData.insertRow(insPos, curMember.getNode(), curMember.getRole());
-      if (insPos >= 0)
-        ++insPos;
-
-      addedNodes.add(curMember.getNode());
-    }
+        RelationMember curMember = relIter.next();
+        if ((curMember.isNode()) && (mainDataSet.isSelected(curMember.getNode())))
+        {
+          stoplistData.insertRow(insPos, curMember.getNode(), curMember.getRole());
+          if (insPos >= 0)
+            ++insPos;
+
+          addedNodes.add(curMember.getNode());
+        }
       }
 
@@ -1530,21 +1531,21 @@
       while (nodeIter.hasNext())
       {
-    Node curMember = nodeIter.next();
-    if (!(addedNodes.contains(curMember)))
-    {
-      stoplistData.insertRow(insPos, curMember, "");
-      if (insPos >= 0)
-        ++insPos;
-    }
+        Node curMember = nodeIter.next();
+        if (!(addedNodes.contains(curMember)))
+        {
+          stoplistData.insertRow(insPos, curMember, "");
+          if (insPos >= 0)
+            ++insPos;
+        }
       }
 
       if ((insPos > 0) && (insPos < stoplistData.getRowCount()))
       {
-    while ((insPos < stoplistData.getRowCount())
-               && (stoplistData.nodes.elementAt(insPos) == null))
-      ++insPos;
-    stoplistTable.removeRowSelectionInterval(0, stoplistData.getRowCount()-1);
-    if (insPos < stoplistData.getRowCount())
-      stoplistTable.addRowSelectionInterval(insPos, insPos);
+        while ((insPos < stoplistData.getRowCount())
+                  && (stoplistData.nodes.elementAt(insPos) == null))
+          ++insPos;
+        stoplistTable.removeRowSelectionInterval(0, stoplistData.getRowCount()-1);
+        if (insPos < stoplistData.getRowCount())
+          stoplistTable.addRowSelectionInterval(insPos, insPos);
       }
 
@@ -1555,9 +1556,9 @@
       for (int i = stoplistData.getRowCount()-1; i >=0; --i)
       {
-    if (stoplistTable.isRowSelected(i))
-    {
-      stoplistData.nodes.removeElementAt(i);
-      stoplistData.removeRow(i);
-    }
+        if (stoplistTable.isRowSelected(i))
+        {
+          stoplistData.nodes.removeElementAt(i);
+          stoplistData.removeRow(i);
+        }
       }
 
@@ -1571,35 +1572,35 @@
       for (int i = 0; i < itineraryData.getRowCount(); ++i)
       {
-    if (itineraryData.ways.elementAt(i) != null)
-    {
-      Way way = itineraryData.ways.elementAt(i);
-      if (!(way.isIncomplete()))
-      {
-        if ("backward".equals((String)(itineraryData.getValueAt(i, 1))))
-        {
-          for (int j = way.getNodesCount()-2; j >= 0; --j)
+        if (itineraryData.ways.elementAt(i) != null)
+        {
+          Way way = itineraryData.ways.elementAt(i);
+          if (!(way.isIncomplete()))
           {
-        SegmentMetric sm = new SegmentMetric
-            (way.getNode(j+1).getCoor().lat(), way.getNode(j+1).getCoor().lon(),
-             way.getNode(j).getCoor().lat(), way.getNode(j).getCoor().lon());
-        segmentMetrics.add(sm);
+            if ("backward".equals((String)(itineraryData.getValueAt(i, 1))))
+            {
+              for (int j = way.getNodesCount()-2; j >= 0; --j)
+              {
+            SegmentMetric sm = new SegmentMetric
+                (way.getNode(j+1).getCoor().lat(), way.getNode(j+1).getCoor().lon(),
+                way.getNode(j).getCoor().lat(), way.getNode(j).getCoor().lon());
+            segmentMetrics.add(sm);
+              }
+            }
+            else
+            {
+              for (int j = 0; j < way.getNodesCount()-1; ++j)
+              {
+            SegmentMetric sm = new SegmentMetric
+                (way.getNode(j).getCoor().lat(), way.getNode(j).getCoor().lon(),
+                way.getNode(j+1).getCoor().lat(), way.getNode(j+1).getCoor().lon());
+            segmentMetrics.add(sm);
+              }
+            }
           }
         }
         else
         {
-          for (int j = 0; j < way.getNodesCount()-1; ++j)
-          {
-        SegmentMetric sm = new SegmentMetric
-            (way.getNode(j).getCoor().lat(), way.getNode(j).getCoor().lon(),
-             way.getNode(j+1).getCoor().lat(), way.getNode(j+1).getCoor().lon());
-        segmentMetrics.add(sm);
-          }
-        }
-      }
-    }
-    else
-    {
-      segmentMetrics.add(null);
-    }
+          segmentMetrics.add(null);
+        }
       }
 
@@ -1610,62 +1611,62 @@
         // Determine for each member its position on the itinerary: position means here the
         // point on the itinerary that has minimal distance to the coor
-    for (int i = stoplistData.getRowCount()-1; i >= 0; --i)
-    {
-      if (stoplistTable.isRowSelected(i))
-      {
-        StopReference sr = detectMinDistance
-        (stoplistData.nodes.elementAt(i), segmentMetrics,
-         cbRight.isSelected(), cbLeft.isSelected());
-        if (sr != null)
-        {
-          if (sr.distance <
-             Double.parseDouble(tfSuggestStopsLimit.getText()) * 9.0 / 1000000.0 )
+        for (int i = stoplistData.getRowCount()-1; i >= 0; --i)
+        {
+          if (stoplistTable.isRowSelected(i))
           {
-        sr.role = (String)stoplistData.getValueAt(i, 1);
-        srm.addElement(sr);
+            StopReference sr = detectMinDistance
+            (stoplistData.nodes.elementAt(i), segmentMetrics,
+            cbRight.isSelected(), cbLeft.isSelected());
+            if (sr != null)
+            {
+              if (sr.distance <
+                Double.parseDouble(tfSuggestStopsLimit.getText()) * 9.0 / 1000000.0 )
+              {
+            sr.role = (String)stoplistData.getValueAt(i, 1);
+            srm.addElement(sr);
+              }
+              else
+              {
+            sr.role = (String)stoplistData.getValueAt(i, 1);
+            sr.index = segmentMetrics.size()*2;
+            sr.pos = 0;
+            srm.addElement(sr);
+              }
+
+              stoplistData.nodes.removeElementAt(i);
+              stoplistData.removeRow(i);
+            }
+
           }
-          else
+        }
+      }
+      else
+      {
+        // Determine for each member its position on the itinerary: position means here the
+            // point on the itinerary that has minimal distance to the coor
+        for (int i = stoplistData.getRowCount()-1; i >= 0; --i)
+        {
+          StopReference sr = detectMinDistance
+              (stoplistData.nodes.elementAt(i), segmentMetrics,
+              cbRight.isSelected(), cbLeft.isSelected());
+          if (sr != null)
           {
-        sr.role = (String)stoplistData.getValueAt(i, 1);
-        sr.index = segmentMetrics.size()*2;
-        sr.pos = 0;
-        srm.addElement(sr);
+            if (sr.distance <
+                  Double.parseDouble(tfSuggestStopsLimit.getText()) * 9.0 / 1000000.0 )
+            {
+              sr.role = (String)stoplistData.getValueAt(i, 1);
+              srm.addElement(sr);
+            }
+            else
+            {
+              sr.role = (String)stoplistData.getValueAt(i, 1);
+              sr.index = segmentMetrics.size()*2;
+              sr.pos = 0;
+              srm.addElement(sr);
+            }
           }
-
-          stoplistData.nodes.removeElementAt(i);
-          stoplistData.removeRow(i);
-        }
-
-      }
-    }
-      }
-      else
-      {
-    // Determine for each member its position on the itinerary: position means here the
-        // point on the itinerary that has minimal distance to the coor
-    for (int i = stoplistData.getRowCount()-1; i >= 0; --i)
-    {
-      StopReference sr = detectMinDistance
-          (stoplistData.nodes.elementAt(i), segmentMetrics,
-           cbRight.isSelected(), cbLeft.isSelected());
-      if (sr != null)
-      {
-        if (sr.distance <
-               Double.parseDouble(tfSuggestStopsLimit.getText()) * 9.0 / 1000000.0 )
-        {
-          sr.role = (String)stoplistData.getValueAt(i, 1);
-          srm.addElement(sr);
-        }
-        else
-        {
-          sr.role = (String)stoplistData.getValueAt(i, 1);
-          sr.index = segmentMetrics.size()*2;
-          sr.pos = 0;
-          srm.addElement(sr);
-        }
-      }
-    }
-
-    stoplistData.clear();
+        }
+
+        stoplistData.clear();
       }
 
@@ -1674,7 +1675,7 @@
       for (int i = 0; i < srm.size(); ++i)
       {
-    stoplistData.insertRow(insPos, srm.elementAt(i).node, srm.elementAt(i).role);
-    if (insPos >= 0)
-      ++insPos;
+        stoplistData.insertRow(insPos, srm.elementAt(i).node, srm.elementAt(i).role);
+        if (insPos >= 0)
+          ++insPos;
       }
 
@@ -1688,29 +1689,29 @@
       if (stoplistTable.getSelectedRowCount() > 0)
       {
-    for (int i = stoplistData.getRowCount()-1; i >=0; --i)
-    {
-      if (stoplistTable.isRowSelected(i))
-      {
-        String role = (String)(stoplistData.getValueAt(i, 1));
-        RelationMember markedNode = new RelationMember
-        (role, stoplistData.nodes.elementAt(i));
-        itemsToReflect.addElement(markedNode);
-
-        stoplistData.nodes.removeElementAt(i);
-        stoplistData.removeRow(i);
-      }
-    }
+        for (int i = stoplistData.getRowCount()-1; i >=0; --i)
+        {
+          if (stoplistTable.isRowSelected(i))
+          {
+            String role = (String)(stoplistData.getValueAt(i, 1));
+            RelationMember markedNode = new RelationMember
+            (role, stoplistData.nodes.elementAt(i));
+            itemsToReflect.addElement(markedNode);
+
+            stoplistData.nodes.removeElementAt(i);
+            stoplistData.removeRow(i);
+          }
+        }
       }
       else
       {
-    for (int i = stoplistData.getRowCount()-1; i >=0; --i)
-    {
-      String role = (String)(stoplistData.getValueAt(i, 1));
-      RelationMember markedNode = new RelationMember
-          (role, stoplistData.nodes.elementAt(i));
-      itemsToReflect.addElement(markedNode);
-    }
-
-    stoplistData.clear();
+        for (int i = stoplistData.getRowCount()-1; i >=0; --i)
+        {
+          String role = (String)(stoplistData.getValueAt(i, 1));
+          RelationMember markedNode = new RelationMember
+              (role, stoplistData.nodes.elementAt(i));
+          itemsToReflect.addElement(markedNode);
+        }
+
+        stoplistData.clear();
       }
 
@@ -1719,14 +1720,14 @@
       while (relIter.hasNext())
       {
-    RelationMember curMember = relIter.next();
-    if (curMember.isNode())
-    {
-      stoplistData.insertRow(insPos, curMember.getNode(), curMember.getRole());
+        RelationMember curMember = relIter.next();
+        if (curMember.isNode())
+        {
+          stoplistData.insertRow(insPos, curMember.getNode(), curMember.getRole());
+          if (insPos >= 0)
+            ++insPos;
+        }
+      }
       if (insPos >= 0)
-        ++insPos;
-    }
-      }
-      if (insPos >= 0)
-    stoplistTable.addRowSelectionInterval(startPos, insPos-1);
+        stoplistTable.addRowSelectionInterval(startPos, insPos-1);
 
       rebuildNodes();
@@ -1739,35 +1740,35 @@
       for (int i = 0; i < itineraryData.getRowCount(); ++i)
       {
-    if (itineraryData.ways.elementAt(i) != null)
-    {
-      Way way = itineraryData.ways.elementAt(i);
-      if (!(way.isIncomplete()))
-      {
-        if ("backward".equals((String)(itineraryData.getValueAt(i, 1))))
-        {
-          for (int j = way.getNodesCount()-2; j >= 0; --j)
+        if (itineraryData.ways.elementAt(i) != null)
+        {
+          Way way = itineraryData.ways.elementAt(i);
+          if (!(way.isIncomplete()))
           {
-        SegmentMetric sm = new SegmentMetric
-            (way.getNode(j+1).getCoor().lat(), way.getNode(j+1).getCoor().lon(),
-             way.getNode(j).getCoor().lat(), way.getNode(j).getCoor().lon());
-        segmentMetrics.add(sm);
+            if ("backward".equals((String)(itineraryData.getValueAt(i, 1))))
+            {
+              for (int j = way.getNodesCount()-2; j >= 0; --j)
+              {
+            SegmentMetric sm = new SegmentMetric
+                (way.getNode(j+1).getCoor().lat(), way.getNode(j+1).getCoor().lon(),
+                way.getNode(j).getCoor().lat(), way.getNode(j).getCoor().lon());
+            segmentMetrics.add(sm);
+              }
+            }
+            else
+            {
+              for (int j = 0; j < way.getNodesCount()-1; ++j)
+              {
+            SegmentMetric sm = new SegmentMetric
+                (way.getNode(j).getCoor().lat(), way.getNode(j).getCoor().lon(),
+                way.getNode(j+1).getCoor().lat(), way.getNode(j+1).getCoor().lon());
+            segmentMetrics.add(sm);
+              }
+            }
           }
         }
         else
         {
-          for (int j = 0; j < way.getNodesCount()-1; ++j)
-          {
-        SegmentMetric sm = new SegmentMetric
-            (way.getNode(j).getCoor().lat(), way.getNode(j).getCoor().lon(),
-             way.getNode(j+1).getCoor().lat(), way.getNode(j+1).getCoor().lon());
-        segmentMetrics.add(sm);
-          }
-        }
-      }
-    }
-    else
-    {
-      segmentMetrics.add(null);
-    }
+          segmentMetrics.add(null);
+        }
       }
 
@@ -1778,67 +1779,65 @@
       if (mainDataSet != null)
       {
-    String stopKey = "";
-    String stopValue = "";
-    if ("bus".equals(currentRoute.get("route")))
-    {
-      stopKey = "highway";
-      stopValue = "bus_stop";
-    }
-    else if ("trolleybus".equals(currentRoute.get("route")))
-    {
-      stopKey = "highway";
-      stopValue = "bus_stop";
-    }
-    else if ("tram".equals(currentRoute.get("route")))
-    {
-      stopKey = "railway";
-      stopValue = "tram_stop";
-    }
-    else if ("light_rail".equals(currentRoute.get("route")))
-    {
-      stopKey = "railway";
-      stopValue = "station";
-    }
-    else if ("subway".equals(currentRoute.get("route")))
-    {
-      stopKey = "railway";
-      stopValue = "station";
-    }
-    else if ("rail".equals(currentRoute.get("route")))
-    {
-      stopKey = "railway";
-      stopValue = "station";
-    }
-
-    Collection< Node > nodeCollection = mainDataSet.getNodes();
-    Iterator< Node > nodeIter = nodeCollection.iterator();
-    while (nodeIter.hasNext())
-    {
-      Node currentNode = nodeIter.next();
-      if (!currentNode.isUsable())
-        continue;
-      if (stopValue.equals(currentNode.get(stopKey)))
-      {
-        StopReference sr = detectMinDistance
-        (currentNode, segmentMetrics,
-         cbRight.isSelected(), cbLeft.isSelected());
-        if ((sr != null) && (sr.distance <
-            Double.parseDouble(tfSuggestStopsLimit.getText()) * 9.0 / 1000000.0 ))
-          srm.addElement(sr);
-      }
-    }
+        String stopKey = "";
+        String stopValue = "";
+        if ("bus".equals(currentRoute.get("route")))
+        {
+          stopKey = "highway";
+          stopValue = "bus_stop";
+        }
+        else if ("trolleybus".equals(currentRoute.get("route")))
+        {
+          stopKey = "highway";
+          stopValue = "bus_stop";
+        }
+        else if ("tram".equals(currentRoute.get("route")))
+        {
+          stopKey = "railway";
+          stopValue = "tram_stop";
+        }
+        else if ("light_rail".equals(currentRoute.get("route")))
+        {
+          stopKey = "railway";
+          stopValue = "station";
+        }
+        else if ("subway".equals(currentRoute.get("route")))
+        {
+          stopKey = "railway";
+          stopValue = "station";
+        }
+        else if ("rail".equals(currentRoute.get("route")))
+        {
+          stopKey = "railway";
+          stopValue = "station";
+        }
+
+        Collection< Node > nodeCollection = mainDataSet.getNodes();
+        Iterator< Node > nodeIter = nodeCollection.iterator();
+        while (nodeIter.hasNext())
+        {
+          Node currentNode = nodeIter.next();
+          if (!currentNode.isUsable())
+            continue;
+          if (stopValue.equals(currentNode.get(stopKey)))
+          {
+            StopReference sr = detectMinDistance
+            (currentNode, segmentMetrics,
+            cbRight.isSelected(), cbLeft.isSelected());
+            if ((sr != null) && (sr.distance <
+                Double.parseDouble(tfSuggestStopsLimit.getText()) * 9.0 / 1000000.0 ))
+              srm.addElement(sr);
+          }
+        }
       }
       else
       {
-    JOptionPane.showMessageDialog(null, "There exists no dataset."
-        + " Try to download data from the server or open an OSM file.",
-     "No data found", JOptionPane.ERROR_MESSAGE);
-
-    System.out.println("Public Transport: RoutePattern: No data found");
-      }
-
-      for (int i = 0; i < stoplistData.getRowCount(); ++i)
-      {
-      }
+        JOptionPane.showMessageDialog(null, tr("There exists no dataset."
+            + " Try to download data from the server or open an OSM file."),
+        tr("No data found"), JOptionPane.ERROR_MESSAGE);
+      }
+
+      /*for (int i = 0; i < stoplistData.getRowCount(); ++i)
+      {
+      }*/
 
       Collections.sort(srm);
@@ -1847,5 +1846,5 @@
       for (int i = 0; i < srm.size(); ++i)
       {
-    stoplistData.addRow(srm.elementAt(i).node, srm.elementAt(i).role);
+        stoplistData.addRow(srm.elementAt(i).node, srm.elementAt(i).role);
       }
 
@@ -1875,21 +1874,21 @@
       while (relIter.hasNext())
       {
-    Relation currentRel = relIter.next();
-    if (!currentRel.isDeleted())
-    {
-      String routeVal = currentRel.get("route");
-      if ("bus".equals(routeVal))
-        relRefs.add(new RouteReference(currentRel));
-      else if ("trolleybus".equals(routeVal))
-        relRefs.add(new RouteReference(currentRel));
-      else if ("tram".equals(routeVal))
-        relRefs.add(new RouteReference(currentRel));
-      else if ("light_rail".equals(routeVal))
-        relRefs.add(new RouteReference(currentRel));
-      else if ("subway".equals(routeVal))
-        relRefs.add(new RouteReference(currentRel));
-      else if ("rail".equals(routeVal))
-        relRefs.add(new RouteReference(currentRel));
-    }
+        Relation currentRel = relIter.next();
+        if (!currentRel.isDeleted())
+        {
+          String routeVal = currentRel.get("route");
+          if ("bus".equals(routeVal))
+            relRefs.add(new RouteReference(currentRel));
+          else if ("trolleybus".equals(routeVal))
+            relRefs.add(new RouteReference(currentRel));
+          else if ("tram".equals(routeVal))
+            relRefs.add(new RouteReference(currentRel));
+          else if ("light_rail".equals(routeVal))
+            relRefs.add(new RouteReference(currentRel));
+          else if ("subway".equals(routeVal))
+            relRefs.add(new RouteReference(currentRel));
+          else if ("rail".equals(routeVal))
+            relRefs.add(new RouteReference(currentRel));
+        }
       }
 
@@ -1898,13 +1897,11 @@
       Iterator< RouteReference > iter = relRefs.iterator();
       while (iter.hasNext())
-    relsListModel.addElement(iter.next());
+        relsListModel.addElement(iter.next());
     }
     else
     {
-      JOptionPane.showMessageDialog(null, "There exists no dataset."
-      + " Try to download data from the server or open an OSM file.",
-   "No data found", JOptionPane.ERROR_MESSAGE);
-
-      System.out.println("Public Transport: No data found");
+      JOptionPane.showMessageDialog(null, tr("There exists no dataset."
+      + " Try to download data from the server or open an OSM file."),
+      tr("No data found"), JOptionPane.ERROR_MESSAGE);
     }
   }
@@ -1924,8 +1921,8 @@
       if (itineraryData.ways.elementAt(i) != null)
       {
-    RelationMember member = new RelationMember
+        RelationMember member = new RelationMember
         ((String)(itineraryData.getValueAt(i, 1)),
          itineraryData.ways.elementAt(i));
-    members.add(member);
+        members.add(member);
       }
     }
@@ -1940,5 +1937,5 @@
       if (currentRoute.getMember(i).isNode())
       {
-    currentRoute.removeMember(i);
+        currentRoute.removeMember(i);
       }
     }
@@ -1970,44 +1967,44 @@
       Node lastListNode = null;
       if ("backward".equals(list.getLast().getRole()))
-    lastListNode = list.getLast().getWay().getNode(0);
+        lastListNode = list.getLast().getWay().getNode(0);
       else
-    lastListNode = list.getLast().getWay().getNode
+        lastListNode = list.getLast().getWay().getNode
         (list.getLast().getWay().getNodesCount() - 1);
       if (lastNode.equals(lastListNode))
       {
-    backNodes.remove(lastListNode);
-    loops.add(list);
+        backNodes.remove(lastListNode);
+        loops.add(list);
       }
       else if (frontNodes.get(lastNode) != null)
       {
-    backNodes.remove(lastListNode);
-    LinkedList<RelationMember> listToAppend = frontNodes.get(lastNode);
-    Iterator<RelationMember> memberIter = list.iterator();
-    while (memberIter.hasNext())
-    {
-      RelationMember member = memberIter.next();
-      if ("backward".equals(member.getRole()))
-        listToAppend.addFirst(new RelationMember("forward", member.getWay()));
+        backNodes.remove(lastListNode);
+        LinkedList<RelationMember> listToAppend = frontNodes.get(lastNode);
+        Iterator<RelationMember> memberIter = list.iterator();
+        while (memberIter.hasNext())
+        {
+          RelationMember member = memberIter.next();
+          if ("backward".equals(member.getRole()))
+            listToAppend.addFirst(new RelationMember("forward", member.getWay()));
+          else
+            listToAppend.addFirst(new RelationMember("backward", member.getWay()));
+        }
+        frontNodes.remove(lastNode);
+        frontNodes.put(lastListNode, listToAppend);
+      }
+      else if (backNodes.get(lastNode) != null)
+      {
+        backNodes.remove(lastListNode);
+        LinkedList<RelationMember> listToAppend = backNodes.get(lastNode);
+        Iterator<RelationMember> memberIter = list.iterator();
+        while (memberIter.hasNext())
+        {
+          RelationMember member = memberIter.next();
+          listToAppend.addLast(member);
+        }
+        backNodes.remove(lastNode);
+        backNodes.put(lastListNode, listToAppend);
+      }
       else
-        listToAppend.addFirst(new RelationMember("backward", member.getWay()));
-    }
-    frontNodes.remove(lastNode);
-    frontNodes.put(lastListNode, listToAppend);
-      }
-      else if (backNodes.get(lastNode) != null)
-      {
-    backNodes.remove(lastListNode);
-    LinkedList<RelationMember> listToAppend = backNodes.get(lastNode);
-    Iterator<RelationMember> memberIter = list.iterator();
-    while (memberIter.hasNext())
-    {
-      RelationMember member = memberIter.next();
-      listToAppend.addLast(member);
-    }
-    backNodes.remove(lastNode);
-    backNodes.put(lastListNode, listToAppend);
-      }
-      else
-    frontNodes.put(lastNode, list);
+        frontNodes.put(lastNode, list);
     }
     else if (backNodes.get(firstNode) != null)
@@ -2019,44 +2016,44 @@
       Node firstListNode = null;
       if ("backward".equals(list.getFirst().getRole()))
-    firstListNode = list.getFirst().getWay().getNode
+        firstListNode = list.getFirst().getWay().getNode
         (list.getFirst().getWay().getNodesCount() - 1);
       else
-    firstListNode = list.getFirst().getWay().getNode(0);
+        firstListNode = list.getFirst().getWay().getNode(0);
       if (lastNode.equals(firstListNode))
       {
-    frontNodes.remove(firstListNode);
-    loops.add(list);
+        frontNodes.remove(firstListNode);
+        loops.add(list);
       }
       else if (frontNodes.get(lastNode) != null)
       {
-    frontNodes.remove(firstListNode);
-    LinkedList<RelationMember> listToAppend = frontNodes.get(lastNode);
-    ListIterator<RelationMember> memberIter = list.listIterator(list.size());
-    while (memberIter.hasPrevious())
-    {
-      RelationMember member = memberIter.previous();
-      listToAppend.addFirst(member);
-    }
-    frontNodes.remove(lastNode);
-    frontNodes.put(firstListNode, listToAppend);
+        frontNodes.remove(firstListNode);
+        LinkedList<RelationMember> listToAppend = frontNodes.get(lastNode);
+        ListIterator<RelationMember> memberIter = list.listIterator(list.size());
+        while (memberIter.hasPrevious())
+        {
+          RelationMember member = memberIter.previous();
+          listToAppend.addFirst(member);
+        }
+        frontNodes.remove(lastNode);
+        frontNodes.put(firstListNode, listToAppend);
       }
       else if (backNodes.get(lastNode) != null)
       {
-    frontNodes.remove(firstListNode);
-    LinkedList<RelationMember> listToAppend = backNodes.get(lastNode);
-    ListIterator<RelationMember> memberIter = list.listIterator(list.size());
-    while (memberIter.hasPrevious())
-    {
-      RelationMember member = memberIter.previous();
-      if ("backward".equals(member.getRole()))
-        listToAppend.addLast(new RelationMember("forward", member.getWay()));
+        frontNodes.remove(firstListNode);
+        LinkedList<RelationMember> listToAppend = backNodes.get(lastNode);
+        ListIterator<RelationMember> memberIter = list.listIterator(list.size());
+        while (memberIter.hasPrevious())
+        {
+          RelationMember member = memberIter.previous();
+          if ("backward".equals(member.getRole()))
+            listToAppend.addLast(new RelationMember("forward", member.getWay()));
+          else
+            listToAppend.addLast(new RelationMember("backward", member.getWay()));
+        }
+        backNodes.remove(lastNode);
+        backNodes.put(firstListNode, listToAppend);
+      }
       else
-        listToAppend.addLast(new RelationMember("backward", member.getWay()));
-    }
-    backNodes.remove(lastNode);
-    backNodes.put(firstListNode, listToAppend);
-      }
-      else
-    backNodes.put(lastNode, list);
+        backNodes.put(lastNode, list);
     }
     else if (frontNodes.get(lastNode) != null)
@@ -2127,7 +2124,7 @@
       if (curMember.isWay())
       {
-    itineraryData.insertRow(insPos, curMember.getWay(), curMember.getRole());
-    if (insPos >= 0)
-      ++insPos;
+        itineraryData.insertRow(insPos, curMember.getWay(), curMember.getRole());
+        if (insPos >= 0)
+          ++insPos;
       }
     }
@@ -2169,8 +2166,8 @@
       if (sm == null)
       {
-    angleLat = 100.0;
-    angleLon = 200.0;
-
-    continue;
+        angleLat = 100.0;
+        angleLon = 200.0;
+
+        continue;
       }
 
@@ -2179,57 +2176,57 @@
       if (curPosition < 0)
       {
-    if (angleLat <= 90.0)
-    {
-      double lastSegAngle = Math.atan2(angleLat - sm.aLat, angleLon - sm.aLon);
-      double segAngle = Math.atan2(sm.d1, -sm.o1);
-      double vertexAngle = Math.atan2(lat - sm.aLat, lon - sm.aLon);
-
-      boolean vertexOnSeg = (vertexAngle == segAngle) ||
-          (vertexAngle == lastSegAngle);
-      boolean vertexOnTheLeft = (!vertexOnSeg) &&
-          (((lastSegAngle > vertexAngle) && (vertexAngle > segAngle))
-          || ((vertexAngle > segAngle) && (segAngle > lastSegAngle))
-          || ((segAngle > lastSegAngle) && (lastSegAngle > vertexAngle)));
-
-      double currentDistance = Math.sqrt((lat - sm.aLat)*(lat - sm.aLat)
-        + (lon - sm.aLon)*(lon - sm.aLon)
-        *Math.cos(sm.aLat * Math.PI/180.0)*Math.cos(sm.aLat * Math.PI/180.0));
-      curPosition = vertexAngle - segAngle;
-      if (vertexOnTheLeft)
-        curPosition = -curPosition;
-      if (curPosition < 0)
-        curPosition += 2*Math.PI;
-      if ((Math.abs(currentDistance) < distance)
-        && (((!vertexOnTheLeft) && (rhsPossible))
-        || ((vertexOnTheLeft) && (lhsPossible))
-           || (vertexOnSeg)))
-      {
-        distance = Math.abs(currentDistance);
-        minIndex = curIndex-1;
-        position = curPosition;
-      }
-    }
-    angleLat = 100.0;
-    angleLon = 200.0;
+        if (angleLat <= 90.0)
+        {
+          double lastSegAngle = Math.atan2(angleLat - sm.aLat, angleLon - sm.aLon);
+          double segAngle = Math.atan2(sm.d1, -sm.o1);
+          double vertexAngle = Math.atan2(lat - sm.aLat, lon - sm.aLon);
+
+          boolean vertexOnSeg = (vertexAngle == segAngle) ||
+              (vertexAngle == lastSegAngle);
+          boolean vertexOnTheLeft = (!vertexOnSeg) &&
+              (((lastSegAngle > vertexAngle) && (vertexAngle > segAngle))
+              || ((vertexAngle > segAngle) && (segAngle > lastSegAngle))
+              || ((segAngle > lastSegAngle) && (lastSegAngle > vertexAngle)));
+
+          double currentDistance = Math.sqrt((lat - sm.aLat)*(lat - sm.aLat)
+            + (lon - sm.aLon)*(lon - sm.aLon)
+            *Math.cos(sm.aLat * Math.PI/180.0)*Math.cos(sm.aLat * Math.PI/180.0));
+          curPosition = vertexAngle - segAngle;
+          if (vertexOnTheLeft)
+            curPosition = -curPosition;
+          if (curPosition < 0)
+            curPosition += 2*Math.PI;
+          if ((Math.abs(currentDistance) < distance)
+            && (((!vertexOnTheLeft) && (rhsPossible))
+            || ((vertexOnTheLeft) && (lhsPossible))
+              || (vertexOnSeg)))
+          {
+            distance = Math.abs(currentDistance);
+            minIndex = curIndex-1;
+            position = curPosition;
+          }
+        }
+        angleLat = 100.0;
+        angleLon = 200.0;
       }
       else if (curPosition > sm.length)
       {
-    angleLat = sm.aLat;
-    angleLon = sm.aLon;
+        angleLat = sm.aLat;
+        angleLon = sm.aLon;
       }
       else
       {
-    double currentDistance = (lat - sm.aLat)*sm.o1 + (lon - sm.aLon)*sm.o2;
-    if ((Math.abs(currentDistance) < distance)
-            && (((currentDistance >= 0) && (rhsPossible))
-            || ((currentDistance <= 0) && (lhsPossible))))
-    {
-      distance = Math.abs(currentDistance);
-      minIndex = curIndex;
-      position = curPosition;
-    }
-
-    angleLat = 100.0;
-    angleLon = 200.0;
+        double currentDistance = (lat - sm.aLat)*sm.o1 + (lon - sm.aLon)*sm.o2;
+        if ((Math.abs(currentDistance) < distance)
+                && (((currentDistance >= 0) && (rhsPossible))
+                || ((currentDistance <= 0) && (lhsPossible))))
+        {
+          distance = Math.abs(currentDistance);
+          minIndex = curIndex;
+          position = curPosition;
+        }
+
+        angleLat = 100.0;
+        angleLon = 200.0;
       }
     }
Index: /applications/editors/josm/plugins/public_transport/src/public_transport/SettingsStoptypeCommand.java
===================================================================
--- /applications/editors/josm/plugins/public_transport/src/public_transport/SettingsStoptypeCommand.java	(revision 26167)
+++ /applications/editors/josm/plugins/public_transport/src/public_transport/SettingsStoptypeCommand.java	(revision 26168)
@@ -1,3 +1,5 @@
 package public_transport;
+
+import static org.openstreetmap.josm.tools.I18n.tr;
 
 import org.openstreetmap.josm.Main;
@@ -47,7 +49,7 @@
       if ((Node)waypointTM.nodes.elementAt(i) != null)
       {
-    Node node = (Node)waypointTM.nodes.elementAt(i);
-    oldStrings.add(new HighwayRailway(node));
-    StopImporterAction.setTagsWrtType(node, type);
+        Node node = (Node)waypointTM.nodes.elementAt(i);
+        oldStrings.add(new HighwayRailway(node));
+        StopImporterAction.setTagsWrtType(node, type);
       }
     }
@@ -57,10 +59,10 @@
       for (int i = 0; i < track.stoplistTM.getRowCount(); ++i)
       {
-    if (track.stoplistTM.nodeAt(i) != null)
-    {
-      Node node = track.stoplistTM.nodeAt(i);
-      oldStrings.add(new HighwayRailway(node));
-      StopImporterAction.setTagsWrtType(node, type);
-    }
+        if (track.stoplistTM.nodeAt(i) != null)
+        {
+          Node node = track.stoplistTM.nodeAt(i);
+          oldStrings.add(new HighwayRailway(node));
+          StopImporterAction.setTagsWrtType(node, type);
+        }
       }
     }
@@ -86,5 +88,5 @@
   @Override public JLabel getDescription()
   {
-    return new JLabel("public_transport.Settings.ChangeStoptype");
+    return new JLabel(tr("Public Transport: Change stop type"));
   }
 
Index: /applications/editors/josm/plugins/public_transport/src/public_transport/StopImporterAction.java
===================================================================
--- /applications/editors/josm/plugins/public_transport/src/public_transport/StopImporterAction.java	(revision 26167)
+++ /applications/editors/josm/plugins/public_transport/src/public_transport/StopImporterAction.java	(revision 26168)
@@ -1,5 +1,4 @@
 package public_transport;
 
-import static org.openstreetmap.josm.tools.I18n.marktr;
 import static org.openstreetmap.josm.tools.I18n.tr;
 
@@ -117,5 +116,5 @@
       }
       JFileChooser fc = new JFileChooser(new File(curDir));
-      fc.setDialogTitle("Select GPX file");
+      fc.setDialogTitle(tr("Select GPX file"));
       fc.setMultiSelectionEnabled(false);
 
@@ -265,8 +264,6 @@
     {
       JOptionPane.showMessageDialog
-      (null, "The GPX file contained no tracks or waypoints.", "No data found",
+      (null, tr("The GPX file contained no tracks or waypoints."), tr("No data found"),
        JOptionPane.ERROR_MESSAGE);
-
-      System.out.println("Public Transport: StopImporter: No data found");
     }
   }
@@ -307,9 +304,7 @@
     if (Main.main.getCurrentDataSet() == null)
     {
-      JOptionPane.showMessageDialog(null, "There exists no dataset."
-      + " Try to download data from the server or open an OSM file.",
-   "No data found", JOptionPane.ERROR_MESSAGE);
-
-      System.out.println("Public Transport: StopInserter: No data found");
+      JOptionPane.showMessageDialog(null, tr("There exists no dataset."
+      + " Try to download data from the server or open an OSM file."),
+     tr("No data found"), JOptionPane.ERROR_MESSAGE);
 
       return null;
@@ -345,10 +340,10 @@
     {
       for (int i = 0; i < selectedLines.length; ++i)
-    consideredLines.add(selectedLines[i]);
+        consideredLines.add(selectedLines[i]);
     }
     else
     {
       for (int i = 0; i < table.getRowCount(); ++i)
-    consideredLines.add(new Integer(i));
+        consideredLines.add(new Integer(i));
     }
     return consideredLines;
@@ -366,6 +361,6 @@
     {
       if ((nodes.elementAt(i) != null) &&
-       (Main.main.getCurrentDataSet().isSelected(nodes.elementAt(i))))
-    table.addRowSelectionInterval(i, i);
+      (Main.main.getCurrentDataSet().isSelected(nodes.elementAt(i))))
+        table.addRowSelectionInterval(i, i);
     }
   }
@@ -381,5 +376,5 @@
       int j = consideredLines.elementAt(i);
       if (nodes.elementAt(j) != null)
-    nodes.elementAt(j).visit(box);
+        nodes.elementAt(j).visit(box);
     }
     if (box.getBounds() == null)
@@ -400,5 +395,5 @@
       int j = consideredLines.elementAt(i);
       if (nodes.elementAt(j) != null)
-    Main.main.getCurrentDataSet().addSelected(nodes.elementAt(j));
+        Main.main.getCurrentDataSet().addSelected(nodes.elementAt(j));
     }
   }
@@ -464,12 +459,12 @@
       public void actionPerformed(ActionEvent e)
       {
-    JTable table = dialog.getStoplistTable();
-    int row = table.getEditingRow();
-    if (row < 0)
-      return;
-    table.clearSelection();
-    table.addRowSelectionInterval(row, row);
-    Main.main.undoRedo.add
-        (new TrackStoplistDeleteCommand(StopImporterAction.this));
+        JTable table = dialog.getStoplistTable();
+        int row = table.getEditingRow();
+        if (row < 0)
+          return;
+        table.clearSelection();
+        table.addRowSelectionInterval(row, row);
+        Main.main.undoRedo.add
+            (new TrackStoplistDeleteCommand(StopImporterAction.this));
       }
     };
Index: /applications/editors/josm/plugins/public_transport/src/public_transport/StopImporterDialog.java
===================================================================
--- /applications/editors/josm/plugins/public_transport/src/public_transport/StopImporterDialog.java	(revision 26167)
+++ /applications/editors/josm/plugins/public_transport/src/public_transport/StopImporterDialog.java	(revision 26168)
@@ -75,17 +75,19 @@
   private JTable waypointTable = null;
 
+  private final String[] stoptypes = new String[]{marktr("bus"), marktr("tram"), marktr("light_rail"), marktr("subway"), marktr("rail")};
+
   public StopImporterDialog(StopImporterAction controller)
   {
     Frame frame = JOptionPane.getFrameForComponent(Main.parent);
-    jDialog = new JDialog(frame, "Create Stops from GPX", false);
+    jDialog = new JDialog(frame, tr("Create Stops from GPX"), false);
     tabbedPane = new JTabbedPane();
     JPanel tabTracks = new JPanel();
-    tabbedPane.addTab(marktr("Tracks"), tabTracks);
+    tabbedPane.addTab(tr("Tracks"), tabTracks);
     JPanel tabSettings = new JPanel();
-    tabbedPane.addTab(marktr("Settings"), tabSettings);
+    tabbedPane.addTab(tr("Settings"), tabSettings);
     JPanel tabStops = new JPanel();
-    tabbedPane.addTab(marktr("Stops"), tabStops);
+    tabbedPane.addTab(tr("Stops"), tabStops);
     JPanel tabWaypoints = new JPanel();
-    tabbedPane.addTab(marktr("Waypoints"), tabWaypoints);
+    tabbedPane.addTab(tr("Waypoints"), tabWaypoints);
     tabbedPane.setEnabledAt(0, true);
     tabbedPane.setEnabledAt(1, true);
@@ -100,5 +102,5 @@
     contentPane.setLayout(gridbag);
 
-    JLabel label = new JLabel("Tracks in this GPX file:");
+    JLabel label = new JLabel(tr("Tracks in this GPX file:"));
 
     layoutCons.gridx = 0;
@@ -134,5 +136,5 @@
     contentPane.setLayout(gridbag);
 
-    label = new JLabel("Type of stops to add");
+    label = new JLabel(tr("Type of stops to add"));
 
     layoutCons.gridx = 0;
@@ -147,9 +149,6 @@
     cbStoptype = new JComboBox();
     cbStoptype.setEditable(false);
-    cbStoptype.addItem("bus");
-    cbStoptype.addItem("tram");
-    cbStoptype.addItem("light_rail");
-    cbStoptype.addItem("subway");
-    cbStoptype.addItem("rail");
+    for(String type : stoptypes)
+        cbStoptype.addItem(new TransText(type));
     cbStoptype.setActionCommand("stopImporter.settingsStoptype");
     cbStoptype.addActionListener(controller);
@@ -164,5 +163,5 @@
     contentPane.add(cbStoptype);
 
-    label = new JLabel("Time on your GPS device");
+    label = new JLabel(tr("Time on your GPS device"));
 
     layoutCons.gridx = 0;
@@ -188,5 +187,5 @@
     contentPane.add(tfGPSTimeStart);
 
-    label = new JLabel("HH:MM:SS.sss");
+    label = new JLabel(tr("HH:MM:SS.sss"));
 
     layoutCons.gridx = 1;
@@ -199,5 +198,5 @@
     contentPane.add(label);
 
-    label = new JLabel("Time on your stopwatch");
+    label = new JLabel(tr("Time on your stopwatch"));
 
     layoutCons.gridx = 0;
@@ -223,5 +222,5 @@
     contentPane.add(tfStopwatchStart);
 
-    label = new JLabel("HH:MM:SS.sss");
+    label = new JLabel(tr("HH:MM:SS.sss"));
 
     layoutCons.gridx = 1;
@@ -234,5 +233,5 @@
     contentPane.add(label);
 
-    label = new JLabel("Time window");
+    label = new JLabel(tr("Time window"));
 
     layoutCons.gridx = 0;
@@ -258,5 +257,5 @@
     contentPane.add(tfTimeWindow);
 
-    label = new JLabel("seconds");
+    label = new JLabel(tr("seconds"));
 
     layoutCons.gridx = 1;
@@ -269,5 +268,5 @@
     contentPane.add(label);
 
-    label = new JLabel("Move Threshold");
+    label = new JLabel(tr("Move Threshold"));
 
     layoutCons.gridx = 0;
@@ -293,5 +292,5 @@
     contentPane.add(tfThreshold);
 
-    label = new JLabel("meters");
+    label = new JLabel(tr("meters"));
 
     layoutCons.gridx = 1;
@@ -304,5 +303,5 @@
     contentPane.add(label);
 
-    JButton bSuggestStops = new JButton("Suggest Stops");
+    JButton bSuggestStops = new JButton(tr("Suggest Stops"));
     bSuggestStops.setActionCommand("stopImporter.settingsSuggestStops");
     bSuggestStops.addActionListener(controller);
@@ -359,5 +358,5 @@
     contentPane.add(tableSP);
 
-    JButton bFind = new JButton("Find");
+    JButton bFind = new JButton(tr("Find"));
     bFind.setActionCommand("stopImporter.stoplistFind");
     bFind.addActionListener(controller);
@@ -372,5 +371,5 @@
     contentPane.add(bFind);
 
-    JButton bShow = new JButton("Show");
+    JButton bShow = new JButton(tr("Show"));
     bShow.setActionCommand("stopImporter.stoplistShow");
     bShow.addActionListener(controller);
@@ -385,5 +384,5 @@
     contentPane.add(bShow);
 
-    JButton bMark = new JButton("Mark");
+    JButton bMark = new JButton(tr("Mark"));
     bMark.setActionCommand("stopImporter.stoplistMark");
     bMark.addActionListener(controller);
@@ -399,5 +398,5 @@
     contentPane.add(bMark);
 
-    JButton bDetach = new JButton("Detach");
+    JButton bDetach = new JButton(tr("Detach"));
     bDetach.setActionCommand("stopImporter.stoplistDetach");
     bDetach.addActionListener(controller);
@@ -413,5 +412,5 @@
     contentPane.add(bDetach);
 
-    JButton bAdd = new JButton("Add");
+    JButton bAdd = new JButton(tr("Add"));
     bAdd.setActionCommand("stopImporter.stoplistAdd");
     bAdd.addActionListener(controller);
@@ -427,5 +426,5 @@
     contentPane.add(bAdd);
 
-    JButton bDelete = new JButton("Delete");
+    JButton bDelete = new JButton(tr("Delete"));
     bDelete.setActionCommand("stopImporter.stoplistDelete");
     bDelete.addActionListener(controller);
@@ -440,5 +439,5 @@
     contentPane.add(bDelete);
 
-    JButton bSort = new JButton("Sort");
+    JButton bSort = new JButton(tr("Sort"));
     bSort.setActionCommand("stopImporter.stoplistSort");
     bSort.addActionListener(controller);
@@ -496,5 +495,5 @@
     contentPane.add(tableSP);
 
-    bFind = new JButton("Find");
+    bFind = new JButton(tr("Find"));
     bFind.setActionCommand("stopImporter.waypointsFind");
     bFind.addActionListener(controller);
@@ -509,5 +508,5 @@
     contentPane.add(bFind);
 
-    bShow = new JButton("Show");
+    bShow = new JButton(tr("Show"));
     bShow.setActionCommand("stopImporter.waypointsShow");
     bShow.addActionListener(controller);
@@ -522,5 +521,5 @@
     contentPane.add(bShow);
 
-    bMark = new JButton("Mark");
+    bMark = new JButton(tr("Mark"));
     bMark.setActionCommand("stopImporter.waypointsMark");
     bMark.addActionListener(controller);
@@ -536,5 +535,5 @@
     contentPane.add(bMark);
 
-    bDetach = new JButton("Detach");
+    bDetach = new JButton(tr("Detach"));
     bDetach.setActionCommand("stopImporter.waypointsDetach");
     bDetach.addActionListener(controller);
@@ -550,5 +549,5 @@
     contentPane.add(bDetach);
 
-    bAdd = new JButton("Enable");
+    bAdd = new JButton(tr("Enable"));
     bAdd.setActionCommand("stopImporter.waypointsAdd");
     bAdd.addActionListener(controller);
@@ -564,5 +563,5 @@
     contentPane.add(bAdd);
 
-    bDelete = new JButton("Disable");
+    bDelete = new JButton(tr("Disable"));
     bDelete.setActionCommand("stopImporter.waypointsDelete");
     bDelete.addActionListener(controller);
@@ -603,5 +602,5 @@
   public String getStoptype()
   {
-    return (String)cbStoptype.getSelectedItem();
+    return ((TransText)cbStoptype.getSelectedItem()).text;
   }
 
@@ -615,5 +614,5 @@
     {
       JOptionPane.showMessageDialog
-      (null, "Can't parse a time from this string.", "Invalid value",
+      (null, tr("Can't parse a time from this string."), tr("Invalid value"),
        JOptionPane.ERROR_MESSAGE);
       return false;
@@ -640,5 +639,5 @@
     {
       JOptionPane.showMessageDialog
-      (null, "Can't parse a time from this string.", "Invalid value",
+      (null, tr("Can't parse a time from this string."), tr("Invalid value"),
        JOptionPane.ERROR_MESSAGE);
       return false;
@@ -675,8 +674,8 @@
     stoplistTable.setModel(model);
     JComboBox comboBox = new JComboBox();
-    comboBox.addItem("");
-    comboBox.addItem("yes");
-    comboBox.addItem("no");
-    comboBox.addItem("implicit");
+    comboBox.addItem(new TransText(null));
+    comboBox.addItem(new TransText(marktr("yes")));
+    comboBox.addItem(new TransText(marktr("no")));
+    comboBox.addItem(new TransText(marktr("implicit")));
     stoplistTable.getColumnModel().getColumn(2)
     .setCellEditor(new DefaultCellEditor(comboBox));
@@ -696,8 +695,8 @@
     waypointTable.setModel(model);
     JComboBox comboBox = new JComboBox();
-    comboBox.addItem("");
-    comboBox.addItem("yes");
-    comboBox.addItem("no");
-    comboBox.addItem("implicit");
+    comboBox.addItem(new TransText(null));
+    comboBox.addItem(new TransText(marktr("yes")));
+    comboBox.addItem(new TransText(marktr("no")));
+    comboBox.addItem(new TransText(marktr("implicit")));
     waypointTable.getColumnModel().getColumn(2)
     .setCellEditor(new DefaultCellEditor(comboBox));
@@ -736,7 +735,7 @@
       int selectedPos = tracksList.getAnchorSelectionIndex();
       if (tracksList.isSelectedIndex(selectedPos))
-    root.tracksSelectionChanged(selectedPos);
+        root.tracksSelectionChanged(selectedPos);
       else
-    root.tracksSelectionChanged(-1);
+        root.tracksSelectionChanged(-1);
     }
   };
Index: /applications/editors/josm/plugins/public_transport/src/public_transport/TrackReference.java
===================================================================
--- /applications/editors/josm/plugins/public_transport/src/public_transport/TrackReference.java	(revision 26167)
+++ /applications/editors/josm/plugins/public_transport/src/public_transport/TrackReference.java	(revision 26168)
@@ -1,5 +1,4 @@
 package public_transport;
 
-import static org.openstreetmap.josm.tools.I18n.marktr;
 import static org.openstreetmap.josm.tools.I18n.tr;
 
@@ -57,6 +56,6 @@
       {
     JOptionPane.showMessageDialog
-        (null, "The GPX file doesn't contain valid trackpoints. "
-        + "Please use a GPX file that has trackpoints.", "GPX File Trouble",
+        (null, tr("The GPX file doesn't contain valid trackpoints. "
+        + "Please use a GPX file that has trackpoints."), tr("GPX File Trouble"),
      JOptionPane.ERROR_MESSAGE);
 
@@ -93,5 +92,5 @@
     String buf = (String)track.getAttributes().get("name");
     if (buf == null)
-      return "unnamed";
+      return tr("unnamed");
     return buf;
   }
@@ -111,5 +110,5 @@
         (stoplistTM.timeAt(e.getFirstRow()), e.getFirstRow(), 0);
     JOptionPane.showMessageDialog
-        (null, "Can't parse a time from this string.", "Invalid value",
+        (null, tr("Can't parse a time from this string."), tr("Invalid value"),
          JOptionPane.ERROR_MESSAGE);
     return;
Index: /applications/editors/josm/plugins/public_transport/src/public_transport/TrackStoplistAddCommand.java
===================================================================
--- /applications/editors/josm/plugins/public_transport/src/public_transport/TrackStoplistAddCommand.java	(revision 26167)
+++ /applications/editors/josm/plugins/public_transport/src/public_transport/TrackStoplistAddCommand.java	(revision 26168)
@@ -1,3 +1,5 @@
 package public_transport;
+
+import static org.openstreetmap.josm.tools.I18n.tr;
 
 import org.openstreetmap.josm.Main;
@@ -43,5 +45,5 @@
   @Override public JLabel getDescription()
   {
-    return new JLabel("public_transport.TrackStoplist.Add");
+    return new JLabel(tr("Public Transport: Add track stop"));
   }
 };
Index: /applications/editors/josm/plugins/public_transport/src/public_transport/TrackStoplistDeleteCommand.java
===================================================================
--- /applications/editors/josm/plugins/public_transport/src/public_transport/TrackStoplistDeleteCommand.java	(revision 26167)
+++ /applications/editors/josm/plugins/public_transport/src/public_transport/TrackStoplistDeleteCommand.java	(revision 26168)
@@ -1,3 +1,5 @@
 package public_transport;
+
+import static org.openstreetmap.josm.tools.I18n.tr;
 
 import org.openstreetmap.josm.Main;
@@ -14,5 +16,5 @@
   private class NodeTimeName
   {
-    NodeTimeName(Node node, String time, String name, String shelter)
+    NodeTimeName(Node node, String time, String name, TransText shelter)
     {
       this.node = node;
@@ -25,5 +27,5 @@
     public String time;
     public String name;
-    public String shelter;
+    public TransText shelter;
   };
 
@@ -44,5 +46,5 @@
       for (int i = 0; i < selectedLines.length; ++i)
       {
-    workingLines.add(selectedLines[i]);
+        workingLines.add(selectedLines[i]);
       }
     }
@@ -50,5 +52,5 @@
     {
       for (int i = 0; i < stoplistTM.getRowCount(); ++i)
-    workingLines.add(new Integer(i));
+        workingLines.add(new Integer(i));
     }
   }
@@ -64,8 +66,8 @@
       (node, (String)stoplistTM.getValueAt(j, 0),
        (String)stoplistTM.getValueAt(j, 1),
-       (String)stoplistTM.getValueAt(j, 2)));
+       (TransText)stoplistTM.getValueAt(j, 2)));
       stoplistTM.removeRow(j);
       if (node == null)
-    continue;
+        continue;
       Main.main.getCurrentDataSet().removePrimitive(node);
       node.setDeleted(true);
@@ -82,5 +84,5 @@
       stoplistTM.insertRow(j, ntn.node, ntn.time, ntn.name, ntn.shelter);
       if (ntn.node == null)
-    continue;
+        continue;
       ntn.node.setDeleted(false);
       Main.main.getCurrentDataSet().addPrimitive(ntn.node);
@@ -96,5 +98,5 @@
   @Override public JLabel getDescription()
   {
-    return new JLabel("public_transport.TrackStoplist.Delete");
+    return new JLabel(tr("Public Transport: Delete track stop"));
   }
 };
Index: /applications/editors/josm/plugins/public_transport/src/public_transport/TrackStoplistDetachCommand.java
===================================================================
--- /applications/editors/josm/plugins/public_transport/src/public_transport/TrackStoplistDetachCommand.java	(revision 26167)
+++ /applications/editors/josm/plugins/public_transport/src/public_transport/TrackStoplistDetachCommand.java	(revision 26168)
@@ -1,3 +1,5 @@
 package public_transport;
+
+import static org.openstreetmap.josm.tools.I18n.tr;
 
 import org.openstreetmap.josm.Main;
@@ -28,10 +30,10 @@
     {
       for (int i = 0; i < selectedLines.length; ++i)
-    consideredLines.add(selectedLines[i]);
+        consideredLines.add(selectedLines[i]);
     }
     else
     {
       for (int i = 0; i < stoplistTM.getRowCount(); ++i)
-    consideredLines.add(new Integer(i));
+        consideredLines.add(new Integer(i));
     }
 
@@ -40,5 +42,5 @@
     {
       if (stoplistTM.nodeAt(consideredLines.elementAt(i)) != null)
-    workingLines.add(consideredLines.elementAt(i));
+        workingLines.add(consideredLines.elementAt(i));
     }
   }
@@ -75,5 +77,5 @@
   @Override public JLabel getDescription()
   {
-    return new JLabel("public_transport.TrackStoplist.Detach");
+    return new JLabel(tr("Public Transport: Detach track stop list"));
   }
 };
Index: /applications/editors/josm/plugins/public_transport/src/public_transport/TrackStoplistNameCommand.java
===================================================================
--- /applications/editors/josm/plugins/public_transport/src/public_transport/TrackStoplistNameCommand.java	(revision 26167)
+++ /applications/editors/josm/plugins/public_transport/src/public_transport/TrackStoplistNameCommand.java	(revision 26168)
@@ -1,3 +1,5 @@
 package public_transport;
+
+import static org.openstreetmap.josm.tools.I18n.tr;
 
 import org.openstreetmap.josm.Main;
@@ -20,5 +22,5 @@
   private String time = null;
   private String oldShelter = null;
-  private String shelter = null;
+  private TransText shelter = null;
   private LatLon oldLatLon = null;
 
@@ -38,6 +40,6 @@
     this.time = (String)trackref.stoplistTM.getValueAt(workingLine, 0);
     this.name = (String)trackref.stoplistTM.getValueAt(workingLine, 1);
-    this.shelter = (String)trackref.stoplistTM.getValueAt(workingLine, 2);
-    if ("".equals(this.shelter))
+    this.shelter = (TransText)trackref.stoplistTM.getValueAt(workingLine, 2);
+    if ("".equals(this.shelter.text))
       this.shelter = null;
   }
@@ -49,5 +51,5 @@
     {
       node.put("name", name);
-      node.put("shelter", shelter);
+      node.put("shelter", shelter.text);
       double dTime = StopImporterDialog.parseTime(time);
       node.setCoor(trackref.computeCoor(dTime));
@@ -62,8 +64,5 @@
     else
       trackref.stoplistTM.setValueAt(name, workingLine, 1);
-    if (shelter == null)
-      trackref.stoplistTM.setValueAt("", workingLine, 2);
-    else
-      trackref.stoplistTM.setValueAt(shelter, workingLine, 2);
+    trackref.stoplistTM.setValueAt(shelter, workingLine, 2);
     trackref.inEvent = false;
     return true;
@@ -88,8 +87,5 @@
     else
       trackref.stoplistTM.setValueAt(oldName, workingLine, 1);
-    if (oldShelter == null)
-      trackref.stoplistTM.setValueAt("", workingLine, 2);
-    else
-      trackref.stoplistTM.setValueAt(oldShelter, workingLine, 2);
+    trackref.stoplistTM.setValueAt(new TransText(oldShelter), workingLine, 2);
     trackref.inEvent = false;
   }
@@ -103,5 +99,5 @@
   @Override public JLabel getDescription()
   {
-    return new JLabel("public_transport.TrackStoplist.Edit");
+    return new JLabel(tr("Public Transport: Edit track stop list"));
   }
 };
Index: /applications/editors/josm/plugins/public_transport/src/public_transport/TrackStoplistRelocateCommand.java
===================================================================
--- /applications/editors/josm/plugins/public_transport/src/public_transport/TrackStoplistRelocateCommand.java	(revision 26167)
+++ /applications/editors/josm/plugins/public_transport/src/public_transport/TrackStoplistRelocateCommand.java	(revision 26168)
@@ -1,3 +1,5 @@
 package public_transport;
+
+import static org.openstreetmap.josm.tools.I18n.tr;
 
 import org.openstreetmap.josm.Main;
@@ -88,5 +90,5 @@
   @Override public JLabel getDescription()
   {
-    return new JLabel("public_transport.TrackStoplist.RelocateNodes");
+    return new JLabel(tr("Public Transport: Relocate nodes in track stoplist"));
   }
 };
Index: /applications/editors/josm/plugins/public_transport/src/public_transport/TrackStoplistSortCommand.java
===================================================================
--- /applications/editors/josm/plugins/public_transport/src/public_transport/TrackStoplistSortCommand.java	(revision 26167)
+++ /applications/editors/josm/plugins/public_transport/src/public_transport/TrackStoplistSortCommand.java	(revision 26168)
@@ -1,3 +1,5 @@
 package public_transport;
+
+import static org.openstreetmap.josm.tools.I18n.tr;
 
 import org.openstreetmap.josm.Main;
@@ -35,10 +37,10 @@
     {
       for (int i = 0; i < selectedLines.length; ++i)
-    workingLines.add(selectedLines[i]);
+        workingLines.add(selectedLines[i]);
     }
     else
     {
       for (int i = 0; i < stoplistTM.getRowCount(); ++i)
-    workingLines.add(new Integer(i));
+        workingLines.add(new Integer(i));
     }
   }
@@ -59,5 +61,5 @@
       (stoplistTM.nodeAt(j), (String)stoplistTM.getValueAt(j, 0),
         (String)stoplistTM.getValueAt(j, 1),
-        (String)stoplistTM.getValueAt(j, 2),
+        (TransText)stoplistTM.getValueAt(j, 2),
          StopImporterDialog.parseTime(stopwatchStart)));
       stoplistTM.removeRow(j);
@@ -73,5 +75,5 @@
       stoplistTM.insertRow(insPos, nse.node, nse.time, nse.name, nse.shelter);
       if (insPos >= 0)
-    ++insPos;
+        ++insPos;
     }
     return true;
@@ -93,5 +95,5 @@
   @Override public JLabel getDescription()
   {
-    return new JLabel("public_transport.TrackStoplist.Sort");
+    return new JLabel(tr("Public Transport: sort track stop list"));
   }
 
@@ -101,9 +103,9 @@
     public String time = null;
     public String name = null;
-    public String shelter = null;
+    public TransText shelter = null;
     public double startTime = 0;
 
     public NodeSortEntry
-        (Node node, String time, String name, String shelter, double startTime)
+        (Node node, String time, String name, TransText shelter, double startTime)
     {
       this.node = node;
@@ -117,16 +119,16 @@
       double time = StopImporterDialog.parseTime(this.time);
       if (time - startTime > 12*60*60)
-    time -= 24*60*60;
+        time -= 24*60*60;
 
       double nseTime = StopImporterDialog.parseTime(nse.time);
       if (nseTime - startTime > 12*60*60)
-    nseTime -= 24*60*60;
+        nseTime -= 24*60*60;
 
       if (time < nseTime)
-    return -1;
+        return -1;
       else if (time > nseTime)
-    return 1;
+        return 1;
       else
-    return 0;
+        return 0;
     }
   };
Index: /applications/editors/josm/plugins/public_transport/src/public_transport/TrackStoplistTableModel.java
===================================================================
--- /applications/editors/josm/plugins/public_transport/src/public_transport/TrackStoplistTableModel.java	(revision 26167)
+++ /applications/editors/josm/plugins/public_transport/src/public_transport/TrackStoplistTableModel.java	(revision 26168)
@@ -1,5 +1,4 @@
 package public_transport;
 
-import static org.openstreetmap.josm.tools.I18n.marktr;
 import static org.openstreetmap.josm.tools.I18n.tr;
 
@@ -20,7 +19,7 @@
     {
       columns = new Vector< String >();
-      columns.add("Time");
-      columns.add("Name");
-      columns.add("Shelter");
+      columns.add(tr("Time"));
+      columns.add(tr("Name"));
+      columns.add(tr("Shelter"));
     }
     nodes = new Vector< Node >();
@@ -49,5 +48,5 @@
   public void insertRow(int insPos, String time)
   {
-    insertRow(insPos, null, time, "", "");
+    insertRow(insPos, null, time, "", new TransText(null));
   }
 
@@ -100,9 +99,7 @@
 
   public void insertRow
-      (int insPos, Node node, String time, String name, String shelter)
+      (int insPos, Node node, String time, String name, TransText shelter)
   {
-    String[] buf = { "", "", "" };
-    buf[0] = time;
-    buf[1] = name;
+    Object[] buf = { time, name, shelter };
     if (insPos == -1)
     {
Index: /applications/editors/josm/plugins/public_transport/src/public_transport/TrackSuggestStopsCommand.java
===================================================================
--- /applications/editors/josm/plugins/public_transport/src/public_transport/TrackSuggestStopsCommand.java	(revision 26167)
+++ /applications/editors/josm/plugins/public_transport/src/public_transport/TrackSuggestStopsCommand.java	(revision 26168)
@@ -1,3 +1,5 @@
 package public_transport;
+
+import static org.openstreetmap.josm.tools.I18n.tr;
 
 import java.util.Collection;
@@ -58,5 +60,5 @@
       Node node = stoplistTM.nodeAt(i);
       if (node == null)
-    continue;
+        continue;
       Main.main.getCurrentDataSet().removePrimitive(node);
       node.setDeleted(true);
@@ -70,5 +72,5 @@
       Iterator< WayPoint > witer = siter.next().getWayPoints().iterator();
       while (witer.hasNext())
-    wayPoints.add(witer.next());
+        wayPoints.add(witer.next());
     }
     Vector< Double > wayPointsDist = new Vector< Double >(wayPoints.size());
@@ -80,8 +82,8 @@
     {
       if (wayPoints.elementAt(i).getString("time") != null)
-    time = StopImporterDialog.parseTime(wayPoints.elementAt(i)
-        .getString("time").substring(11,19));
+        time = StopImporterDialog.parseTime(wayPoints.elementAt(i)
+            .getString("time").substring(11,19));
       if (time < dGpsStartTime)
-    time += 24*60*60;
+        time += 24*60*60;
       wayPointsDist.add(Double.valueOf(Double.POSITIVE_INFINITY));
       ++i;
@@ -93,10 +95,10 @@
       while ((j > 0) && (time - timeWindow/2 < time2))
       {
-    --j;
-    if (wayPoints.elementAt(j).getString("time") != null)
-      time2 = StopImporterDialog.parseTime(wayPoints.elementAt(j)
-          .getString("time").substring(11,19));
-    if (time2 < dGpsStartTime)
-      time2 += 24*60*60;
+        --j;
+        if (wayPoints.elementAt(j).getString("time") != null)
+          time2 = StopImporterDialog.parseTime(wayPoints.elementAt(j)
+              .getString("time").substring(11,19));
+        if (time2 < dGpsStartTime)
+          time2 += 24*60*60;
       }
       int k = i + 1;
@@ -104,32 +106,32 @@
       while ((k < wayPoints.size()) && (time + timeWindow/2 > time2))
       {
-    if (wayPoints.elementAt(k).getString("time") != null)
-      time2 = StopImporterDialog.parseTime(wayPoints.elementAt(k)
-          .getString("time").substring(11,19));
-    if (time2 < dGpsStartTime)
-      time2 += 24*60*60;
-    ++k;
+        if (wayPoints.elementAt(k).getString("time") != null)
+          time2 = StopImporterDialog.parseTime(wayPoints.elementAt(k)
+              .getString("time").substring(11,19));
+        if (time2 < dGpsStartTime)
+          time2 += 24*60*60;
+        ++k;
       }
 
       if (j < k)
       {
-    double dist = 0;
-    LatLon latLonI = wayPoints.elementAt(i).getCoor();
-    for (int l = j; l < k; ++l)
-    {
-      double distL = latLonI.greatCircleDistance(wayPoints.elementAt(l).getCoor());
-      if (distL > dist)
-        dist = distL;
-    }
-    wayPointsDist.add(Double.valueOf(dist));
+        double dist = 0;
+        LatLon latLonI = wayPoints.elementAt(i).getCoor();
+        for (int l = j; l < k; ++l)
+        {
+          double distL = latLonI.greatCircleDistance(wayPoints.elementAt(l).getCoor());
+          if (distL > dist)
+            dist = distL;
+        }
+        wayPointsDist.add(Double.valueOf(dist));
       }
       else
-    wayPointsDist.add(Double.valueOf(Double.POSITIVE_INFINITY));
+        wayPointsDist.add(Double.valueOf(Double.POSITIVE_INFINITY));
 
       if (wayPoints.elementAt(i).getString("time") != null)
-    time = StopImporterDialog.parseTime(wayPoints.elementAt(i)
-        .getString("time").substring(11,19));
+        time = StopImporterDialog.parseTime(wayPoints.elementAt(i)
+            .getString("time").substring(11,19));
       if (time < dGpsStartTime)
-    time += 24*60*60;
+        time += 24*60*60;
       ++i;
     }
@@ -139,24 +141,24 @@
     {
       if (wayPointsDist.elementAt(i).doubleValue() >= threshold)
-    continue;
+        continue;
       if ((wayPointsDist.elementAt(i).compareTo(wayPointsDist.elementAt(i-1)) != -1)
        || (wayPointsDist.elementAt(i).compareTo(wayPointsDist.elementAt(i+1)) != -1))
-    continue;
+        continue;
 
       LatLon latLon = wayPoints.elementAt(i).getCoor();
       if ((lastStopCoor != null) &&  (lastStopCoor.greatCircleDistance(latLon) < threshold))
-    continue;
+        continue;
 
       if (wayPoints.elementAt(i).getString("time") != null)
       {
-    time = StopImporterDialog.parseTime(wayPoints.elementAt(i)
-        .getString("time").substring(11,19));
-    double gpsSyncTime = StopImporterDialog.parseTime(this.gpsSyncTime);
-    if (gpsSyncTime < dGpsStartTime - 12*60*60)
-      gpsSyncTime += 24*60*60;
-    double timeDelta = gpsSyncTime - StopImporterDialog.parseTime(stopwatchStart);
-    time -= timeDelta;
-    Node node = StopImporterAction.createNode(latLon, type, "");
-    stoplistTM.insertRow(-1, node, StopImporterAction.timeOf(time), "", "");
+        time = StopImporterDialog.parseTime(wayPoints.elementAt(i)
+            .getString("time").substring(11,19));
+        double gpsSyncTime = StopImporterDialog.parseTime(this.gpsSyncTime);
+        if (gpsSyncTime < dGpsStartTime - 12*60*60)
+          gpsSyncTime += 24*60*60;
+        double timeDelta = gpsSyncTime - StopImporterDialog.parseTime(stopwatchStart);
+        time -= timeDelta;
+        Node node = StopImporterAction.createNode(latLon, type, "");
+        stoplistTM.insertRow(-1, node, StopImporterAction.timeOf(time), "", new TransText(null));
       }
 
@@ -175,5 +177,5 @@
       Node node = stoplistTM.nodeAt(i);
       if (node == null)
-    continue;
+        continue;
       Main.main.getCurrentDataSet().removePrimitive(node);
       node.setDeleted(true);
@@ -188,5 +190,5 @@
       Node node = stoplistTM.nodeAt(i);
       if (node == null)
-    continue;
+        continue;
       node.setDeleted(false);
       Main.main.getCurrentDataSet().addPrimitive(node);
@@ -202,5 +204,5 @@
   @Override public JLabel getDescription()
   {
-    return new JLabel("public_transport.TrackStoplist.SuggestStops");
+    return new JLabel(tr("Public Transport: Suggest stops"));
   }
 
@@ -223,16 +225,16 @@
       double time = StopImporterDialog.parseTime(this.time);
       if (time - startTime > 12*60*60)
-    time -= 24*60*60;
+        time -= 24*60*60;
 
       double nseTime = StopImporterDialog.parseTime(nse.time);
       if (nseTime - startTime > 12*60*60)
-    nseTime -= 24*60*60;
+        nseTime -= 24*60*60;
 
       if (time < nseTime)
-    return -1;
+        return -1;
       else if (time > nseTime)
-    return 1;
+        return 1;
       else
-    return 0;
+        return 0;
     }
   };
Index: /applications/editors/josm/plugins/public_transport/src/public_transport/TransText.java
===================================================================
--- /applications/editors/josm/plugins/public_transport/src/public_transport/TransText.java	(revision 26168)
+++ /applications/editors/josm/plugins/public_transport/src/public_transport/TransText.java	(revision 26168)
@@ -0,0 +1,16 @@
+package public_transport;
+
+import static org.openstreetmap.josm.tools.I18n.tr;
+
+public class TransText
+{
+    public String text;
+    public TransText(String t)
+    {
+        text = t;
+    }
+    public String toString()
+    {
+        return text == null ? "" : tr(text);
+    }
+}
Index: /applications/editors/josm/plugins/public_transport/src/public_transport/WaypointTableModel.java
===================================================================
--- /applications/editors/josm/plugins/public_transport/src/public_transport/WaypointTableModel.java	(revision 26167)
+++ /applications/editors/josm/plugins/public_transport/src/public_transport/WaypointTableModel.java	(revision 26168)
@@ -1,5 +1,4 @@
 package public_transport;
 
-import static org.openstreetmap.josm.tools.I18n.marktr;
 import static org.openstreetmap.josm.tools.I18n.tr;
 
@@ -25,7 +24,7 @@
   {
     this.controller = controller;
-    addColumn("Time");
-    addColumn("Stopname");
-    addColumn("Shelter");
+    addColumn(tr("Time"));
+    addColumn(tr("Stopname"));
+    addColumn(tr("Shelter"));
     addTableModelListener(this);
   }
@@ -55,14 +54,14 @@
   public void insertRow(int insPos, WayPoint wp)
   {
-    String[] buf = { "", "", "" };
-    buf[0] = wp.getString("time");
-    if (buf[0] == null)
-      buf[0] = "";
-    buf[1] = wp.getString("name");
-    if (buf[1] == null)
-      buf[1] = "";
+    String time = wp.getString("time");
+    if (time == null)
+      time = "";
+    String name = wp.getString("name");
+    if (name == null)
+      name = "";
 
-    Node node = controller.createNode(wp.getCoor(), buf[1]);
+    Node node = controller.createNode(wp.getCoor(), name);
 
+    Object[] buf = { time, name, new TransText(null) };
     if (insPos == -1)
     {
@@ -90,8 +89,8 @@
     {
       if (inEvent)
-    return;
+        return;
       Main.main.undoRedo.add(new WaypointsNameCommand
       (this, e.getFirstRow(), (String)getValueAt(e.getFirstRow(), 1),
-       (String)getValueAt(e.getFirstRow(), 2)));
+       (TransText)getValueAt(e.getFirstRow(), 2)));
     }
   }
Index: /applications/editors/josm/plugins/public_transport/src/public_transport/WaypointsDetachCommand.java
===================================================================
--- /applications/editors/josm/plugins/public_transport/src/public_transport/WaypointsDetachCommand.java	(revision 26167)
+++ /applications/editors/josm/plugins/public_transport/src/public_transport/WaypointsDetachCommand.java	(revision 26168)
@@ -1,3 +1,5 @@
 package public_transport;
+
+import static org.openstreetmap.josm.tools.I18n.tr;
 
 import org.openstreetmap.josm.Main;
@@ -75,5 +77,5 @@
   @Override public JLabel getDescription()
   {
-    return new JLabel("public_transport.Waypoints.Detach");
+    return new JLabel(tr("Public Transport: Detach waypoints"));
   }
 };
Index: /applications/editors/josm/plugins/public_transport/src/public_transport/WaypointsDisableCommand.java
===================================================================
--- /applications/editors/josm/plugins/public_transport/src/public_transport/WaypointsDisableCommand.java	(revision 26167)
+++ /applications/editors/josm/plugins/public_transport/src/public_transport/WaypointsDisableCommand.java	(revision 26168)
@@ -1,3 +1,5 @@
 package public_transport;
+
+import static org.openstreetmap.josm.tools.I18n.tr;
 
 import org.openstreetmap.josm.Main;
@@ -83,5 +85,5 @@
   @Override public JLabel getDescription()
   {
-    return new JLabel("public_transport.Waypoints.Disable");
+    return new JLabel(tr("Public Transport: Disable waypoints"));
   }
 };
Index: /applications/editors/josm/plugins/public_transport/src/public_transport/WaypointsEnableCommand.java
===================================================================
--- /applications/editors/josm/plugins/public_transport/src/public_transport/WaypointsEnableCommand.java	(revision 26167)
+++ /applications/editors/josm/plugins/public_transport/src/public_transport/WaypointsEnableCommand.java	(revision 26168)
@@ -1,3 +1,5 @@
 package public_transport;
+
+import static org.openstreetmap.josm.tools.I18n.tr;
 
 import org.openstreetmap.josm.Main;
@@ -28,10 +30,10 @@
     {
       for (int i = 0; i < selectedLines.length; ++i)
-    consideredLines.add(selectedLines[i]);
+        consideredLines.add(selectedLines[i]);
     }
     else
     {
       for (int i = 0; i < waypointTM.getRowCount(); ++i)
-    consideredLines.add(new Integer(i));
+        consideredLines.add(new Integer(i));
     }
 
@@ -40,5 +42,5 @@
     {
       if (waypointTM.nodes.elementAt(consideredLines.elementAt(i)) == null)
-    workingLines.add(consideredLines.elementAt(i));
+        workingLines.add(consideredLines.elementAt(i));
     }
   }
@@ -51,8 +53,6 @@
       Node node = StopImporterAction.createNode
         (waypointTM.coors.elementAt(j), type, (String)waypointTM.getValueAt(j, 1));
-      if ("".equals((String)waypointTM.getValueAt(j, 2)))
-    node.put("shelter", null);
-      else
-    node.put("shelter", (String)waypointTM.getValueAt(j, 2));
+      TransText shelter = (TransText)waypointTM.getValueAt(j, 2);
+      node.put("shelter", shelter.text);
       waypointTM.nodes.set(j, node);
     }
@@ -68,5 +68,5 @@
       waypointTM.nodes.set(j, null);
       if (node == null)
-    continue;
+        continue;
       Main.main.getCurrentDataSet().removePrimitive(node);
       node.setDeleted(true);
@@ -82,5 +82,5 @@
   @Override public JLabel getDescription()
   {
-    return new JLabel("public_transport.Waypoints.Enable");
+    return new JLabel(tr("Public Transport: Enable waypoints"));
   }
 };
Index: /applications/editors/josm/plugins/public_transport/src/public_transport/WaypointsNameCommand.java
===================================================================
--- /applications/editors/josm/plugins/public_transport/src/public_transport/WaypointsNameCommand.java	(revision 26167)
+++ /applications/editors/josm/plugins/public_transport/src/public_transport/WaypointsNameCommand.java	(revision 26168)
@@ -1,3 +1,5 @@
 package public_transport;
+
+import static org.openstreetmap.josm.tools.I18n.tr;
 
 import org.openstreetmap.josm.Main;
@@ -17,8 +19,8 @@
   private String name = null;
   private String oldShelter = null;
-  private String shelter = null;
+  private TransText shelter;
 
   public WaypointsNameCommand
-      (WaypointTableModel waypointTM, int workingLine, String name, String shelter)
+      (WaypointTableModel waypointTM, int workingLine, String name, TransText shelter)
   {
     this.waypointTM = waypointTM;
@@ -31,6 +33,4 @@
     this.name = name;
     this.shelter = shelter;
-    if ("".equals(shelter))
-      this.shelter = null;
   }
 
@@ -40,5 +40,5 @@
     {
       waypointTM.nodes.elementAt(workingLine).put("name", name);
-      waypointTM.nodes.elementAt(workingLine).put("shelter", shelter);
+      waypointTM.nodes.elementAt(workingLine).put("shelter", shelter.text);
     }
     waypointTM.inEvent = true;
@@ -47,8 +47,5 @@
     else
       waypointTM.setValueAt(name, workingLine, 1);
-    if (shelter == null)
-      waypointTM.setValueAt("", workingLine, 2);
-    else
-      waypointTM.setValueAt(shelter, workingLine, 2);
+    waypointTM.setValueAt(shelter, workingLine, 2);
     waypointTM.inEvent = false;
     return true;
@@ -67,8 +64,5 @@
     else
       waypointTM.setValueAt(oldName, workingLine, 1);
-    if (oldShelter == null)
-      waypointTM.setValueAt("", workingLine, 2);
-    else
-      waypointTM.setValueAt(oldShelter, workingLine, 2);
+    waypointTM.setValueAt(new TransText(oldShelter), workingLine, 2);
     waypointTM.inEvent = false;
   }
@@ -82,5 +76,5 @@
   @Override public JLabel getDescription()
   {
-    return new JLabel("public_transport.Waypoints.EditName");
+    return new JLabel(tr("Public Transport: Edit waypoint name"));
   }
 };
