Well that’s often not so easy because of different coding philosophies: I certainly would have to do more testing. But fun fact in the source code the buttons are called SideButton. How a SideButton got placed at the bottom is a mystery.
Me happy, great work!
Just in case you get inspired again and implement way object templates: two-node ways are enough. E.g. a tree row, a weir, a hedge.
Well I don’t see a real advantage for ways. It would have a default length, so you have to move it to a tree row, click on at least one of the nodes to change the length to length of the existing tree row. If the tree row is not in a straight line you have to add even more nodes. Just creating a new way and then add the tags with a one click JOSM preset will be as quick.
Well I’ve come up with a new idea, it’s not supporting storing way templates but I think it’s even better.
With the newest version it’s possible to auto tag objects that are selected, this includes ways if it was enabled for the node template via the context menu of that template. So you can now create a node with the tag natural=tree_row add that as a template to the node template list. Then open the context menu for the new template and enable the usage on ways and disable the usage on nodes (so that no wrongly tagged nodes are created accidentally). When you click on a template the auto tagging is activated (by default it stays active for 10 seconds, can be changed via the little preferences button in the title bar of the node template list). Each way that you select (while the auto tagging is active) will be tagged with natural=tree_row. Since new drawn ways are also selected automatically this also works when drawing. Combined with KindaHackedInUtils it easily can be used for adding nodes, for example select a tree template and press B on the keyboard and a new tree node is created at the mouse position. Every new selection resets the timer.
I’ve had problems with accidentally tagging objects that weren’t supposed to get tagged. So I’ve added more options.
- when auto tagging is active pressing
Von the keyboard will deactivate it - a new preference allows to disable auto tagging on selecting node templates
ALT+Left click(or clicking 4 times) will still activate auto tagging when selecting node templatesALT+SHIFT+Left click(or clicking 5 times) will activate auto tagging without timer when selecting node templates (ALT+SHIFT+Left clickalso works on the auto tagging checkbox)
Additionally I made it possible to have up to 7 columns of node templates to make better use of the horizontal screen real estate and reduce vertical. The default is up to 3, it is dynamic so if the space is enough to get the node templates into one column, only one column will be displayed. The number of columns shown increases when needed up to the maximum that was selected in the preferences.
I’ve come up with an idea to further reduce the number of node templates needed. For nodes that have tags that are always present but other tags that are different it’s now possible to enter those optional tags for pressing Ctrl or Shift on the keyboard while creating a new node. For example the give_way sign has to have a direction of forward or backward. So instead of creating 2 node templates for this sign with each direction it’s now possible to set direction=forward as optional tag for pressing Ctrl or Shift and the direction=backward tag for the other key, so that only one node template is needed to create nodes with the correct direction.
This will also work for auto tagging but since the map uses the keys Ctrl and Shift it’s only possible to draw ways with Ctrl pressed because Shift causes the draw mode only to draw nodes. For drawing nodes in the draw mode both keys are working.
It’s now also possible to edit the tags directly for the node template.
