1 | | {{{ |
2 | | #!comment |
3 | | This contains the list of external style addresses in alphabetical order. (Only addresses with file-extension are supported.) |
4 | | It will be parsed about each 10 minutes and is used to update the styles list. |
5 | | |
6 | | https://raw.githubusercontent.com/species/josm-preset-wheelchair/master/sidewalks_kerbs.mapcss |
7 | | https://raw.githubusercontent.com/OpenSeaMap/josm/master/seamark_styles.xml |
8 | | http://download.freemap.sk/JOSM/conscriptionnumbers.mapcss |
9 | | https://github.com/avar/osmis-josm-style/raw/master/elemstyles_is.xml |
10 | | https://github.com/bastik/mapcss-tools/raw/osm/mapnik2mapcss/osm-results/mapnik.zip |
11 | | http://osmalba.org/josm_styles/naptan_bus_stops.zip |
12 | | http://www.freietonne.de/ft_icons/josm/FreieTonne_rules_presets_zip.php |
13 | | https://dl.dropbox.com/u/8010189/Forum%20attachments/Hide_nodes.mapcss |
14 | | https://github.com/simon04/coloured-addresses.mapcss/raw/master/dist/coloured-addresses.mapcss |
15 | | https://raw.github.com/molysgaard/OAM-JOSM/master/oam-style.mapcss |
16 | | https://github.com/hotosm/HDM-JOSM-style/archive/master.zip |
17 | | https://github.com/DisasterNetDOTOrg/HOT-Osm-Validation/archive/master.zip |
18 | | http://maps.openstreetmap.ie/josm/townland.mapcss |
19 | | |
20 | | Dead link: |
21 | | http://maps.tilusnet.com/josmdata/elemstyles_nolabels.xml |
22 | | https://raw.github.com/gist/1277481/railway.mapcss |
23 | | }}} |
24 | | {{{ |
25 | | #!comment |
26 | | Note for translators: |
27 | | - The above list and this note can be stripped from translation. |
28 | | - The reference below to change the source of this page should be modified, so it tells the reader to modify the English page. |
29 | | }}} |
33 | | [[Image(source:trunk/images/dialogs/mapstyle.png,middle,margin-right=20)]] |
34 | | The JOSM map display can be customized with different styles. |
| 5 | [[JOSMImage(dialogs/mapstyle,middle,margin-right=20,48,link=)]] The JOSM [wikitr:/Help/MapView map display] can be easily customized with different styles. Many styles are included with JOSM by default. |
| 6 | |
| 7 | There are ''base styles'' (e.g. [source:/trunk/resources/styles/standard/elemstyles.mapcss JOSM standard] or [wiki:/Styles/Potlatch2 Potlatch 2]) that cover a wide range of features each. They can be combined with ''add-on styles'' that cover more special topics. See the [#Availablestyleslist available styles list] below. |
| 8 | |
| 9 | Further customization is possible via [#AdvancedPreferences style options] or by [#CreateStyle creating your own style]. |
| 10 | |
| 11 | == Choose styles ==#ChooseStyles |
| 12 | JOSM has ''three lists'' of ''map styles:'' available styles (all styles from the style repository) → active styles (your favourites) → ☑ chosen styles (actually used for the map painting). |
| 13 | |
| 14 | JOSM comes with some styles being in the "active styles" list by default. You can choose styles from this list of "active styles" to be actually used for the map painting by clicking the check box (☑) at the desired style's line |
| 15 | * in the [wikitr:/Help/Dialog/MapPaint map paint style dialog] or |
| 16 | * in the [wikitr:/Help/Menu/View "View" menu] ( → "Map paint styles") or |
| 17 | * in the Map Paint Styles Preferences (see section below) |
| 18 | |
| 19 | Note that, unless you are working with add-on styles, likely you want to have only one style ☑ checked at a time. |
| 20 | |
| 21 | === Activating more styles === |
| 22 | ''Instructions:'' |
| 23 | |
| 24 | 1. Open the [wikitr:/Help/Preferences/MapPaintPreference Map Paint Styles preferences] |
| 25 | * via the header of the Map Paint Styles panel with the [[JOSMImage(dialogs/mappaintpreference)]] [wikitr:/Help/Dialog/MapPaint#MapStyleSettings Preferences] button or [[Image(addstyle.gif,right,250px,title=animation of how to activate and choose an example style,margin=10,link=)]] |
| 26 | * via [wikitr:/Help/Menu/View View menu] → ''Map paint styles'' → ''Map paint preferences'' or |
| 27 | * via the general preferences dialog [wikitr:/Help/Menu/Edit Menu Edit] → [wikitr:/Help/Action/Preferences Preferences] → [[JOSMImage(dialogs/mapstyle,24,middle,link=)]] [wikitr:/Help/Preferences/MapPaintPreference Map Paint Styles] |
| 28 | 1. Choose a style in the list of ''Available styles'' (left side) |
| 29 | 1. Activate it by clicking the [[JOSMImage(preferences/activate-right)]] blue right arrow button between the lists. |
| 30 | 1. Exit and confirm by clicking the OK button |
| 31 | |
| 32 | ''Example:'' Let's assume that you want to add [osmwiki:Key:maxspeed maxspeed=*] tags to OSM, then you probably will make use of the style [wikitr:/Styles/Maxspeed Maxspeed] (which displays the value of maxspeed on roads with different colors). The screencast/animation on the right side (click to enlarge) shows how to add this style to your list of "active styles". |
| 33 | |
| 34 | ==== Adding own styles ==== |
| 35 | You can add own styles (from any URL/file) to the list of active styles – for example a style file which you have [#CreateStyle created yourself]. Just click the [[JOSMImage(dialogs/add)]] plus sign on the right and enter either path and filename or URL of your style file. |
69 | | * Either edit this wiki page and add URLs for new style files to the list at the top. |
70 | | * **Note**: Only URLs with file-extension (e.g. *.mapcss, *.xml, *.zip, *.php) are supported. |
71 | | * Or create a wiki page similar to [[Styles/LegacyStandard]] (XML) or [[Styles/Modified]] (MapCSS). |
72 | | * for automatical version adjustment you can use two internal variables ({{{"1.[[revision]]_[[date]]" --> 1.13_2011-02-24}}}): |
73 | | 1. {{{[[revision]]}}} - is the latest version number of the wiki page |
74 | | 1. {{{[[date]]}}} - is the date of the last edit |
75 | | * **Note**: Spam filter prohibits adding many external (icon) links. Please, if possible, attach icons to the wiki page ([#Iconhandling see below]). |
| 54 | * Either create a wiki page similar to [wiki:Styles/Modified]. |
| 55 | I. go to [wiki:Styles/MyStyleName https://josm.openstreetmap.de/wiki/Styles/MyStyleName] |
| 56 | A. change the URL so it matches the name of your style; change only the last part after `...Styles/`, (preferred is CamelCase) |
| 57 | a. press `Enter` after adjusting the name |
| 58 | 1. don't forget to enclose your mappaint code by a code block (`#!style type="mapcss"` needs to be on a **new line** after `{{{`): |
| 59 | 1. `{{{` |
| 60 | 1. `#!style type="mapcss"` |
| 61 | 1. ... |
| 62 | 1. `}}}` |
| 63 | 1. for automatic version adjustment you have to use `[[revision]]_[[date]]` in your version variable: |
| 64 | * `[[revision]]` - is the latest version number of the wiki page |
| 65 | * `[[date]]` - is the date of the last edit of the wiki page |
| 66 | * recommended usage: `version="1.[[revision]]_[[date]]"` (converts to e.g. `1.13_2019-02-24`) |
| 67 | * this is required for an automatic update within JOSM |
| 68 | * **Note**: Spam filter prohibits adding many external (icon) links. Please, if possible, attach icons to the wiki page ([#Iconhandling see below]). … |
| 69 | * '''or''' edit the page StylesSource and add URLs for new style files to the list at the top. (JOSM wiki based Styles (see above) is the preferred method.) |
| 70 | * **Note**: Only URLs with file-extension (e.g. *.mapcss, *.zip, *.php) are supported. |
84 | | * Icons distributed with JOSM can be entered directly with the path (relative to JOSM's internal image directory). |
85 | | * Use a path relative to your local style file. |
86 | | * New icons can be directly referenced using a http-link. These are downloaded and cached internally. |
87 | | * Since JOSM revision [/changeset/2289/josm 2289] zip files are supported. |
88 | | * The zip file must contain at least one file with extension xml (or mapcss). |
| 82 | * Icons distributed with JOSM can be entered directly with the path (relative to JOSM's [source:/trunk/resources/images internal image directory]). |
| 83 | * Use a path relative to your local style file. (This works only for Styles, not for Presets.) |
| 84 | * Use a path relative to a directory specified at the bottom in the [wikitr:/Help/Preferences/MapPaintPreference Map Paint Styles preferences] or [wikitr:/Help/Preferences/TaggingPresetPreference Tagging Presets preferences].) |
| 85 | * New icons can be directly referenced using a https- or http-link. These are downloaded and cached internally. |
| 86 | * zip files are supported too. |
| 87 | * The zip file must contain at least one file with extension mapcss (for styles) or xml (for presets). |
90 | | * If there are multiple XML files, a file with "style" in the name is preferred (to allow packaging styles and presets in one archive). |
91 | | * When the JOSM wiki is used for designing of new styles you have some additional options: |
| 89 | * If there are multiple files, a file with "style" in the name is preferred (to allow packaging styles and presets in one archive). |
| 90 | * Inline encoding as described in [https://tools.ietf.org/html/rfc2397 RFC 2397] is supported too. |
| 91 | * Example for PNG: `data:image/png;base64,...databytes...` |
| 92 | * Example for SVG: `data:image/svg+xml;base64,...databytes...` |
| 93 | * [wikitr:/Help/Base64 More information] about `data:image/...` in JOSM. |
| 94 | * When the JOSM wiki is used for designing of new styles or presets you have some additional options: |
| 100 | == Translation == |
| 101 | Styles, Rules, Presets and Plugins use the same translation mechanism as JOSM core. The files must be delivered as Zip and contain a directory called `data` with the .lang files. |
| 102 | To create these files there exist scripts in the SVN directory [source:osm/applications/editors/josm/i18n/ i18n]. |
| 103 | See also [wikitr:/Translations#Software software translation section] in translation documentation. |
| 104 | |
| 105 | == Updating styles in JOSM == |
| 106 | Once a style was updated in the wiki (or another external source) it takes up to 10 days until the style gets updated in JOSM automatically (#8933). To immediately force an update you can do the following steps: |
| 107 | * Open the [wikitr:/Help/Action/Preferences Preferences] |
| 108 | * Make sure [wikitr:/Help/ExpertMode Expert mode] is enabled |
| 109 | * Open the [wikitr:/Help/Preferences/Advanced Advanced Preferences] |
| 110 | * Search for keys starting with: `mirror.https://josm.openstreetmap.de/josmfile?page_Styles/` (or `mirror.` for other external sources) |
| 111 | * Select the style you want to update |
| 112 | * Click on Reset at the bottom of the window |
| 113 | * Click on OK to save the changes (and to close the preference window) |
| 114 | * Restart JOSM |
| 115 | |
| 116 | or: |
| 117 | |
| 118 | * Remove the content of your [wikitr:/Help/Action/About#InstallationDetails <josm.cache>] folder |
| 119 | * Restart JOSM |
| 120 | |
| 121 | To check the version of the style in JOSM do the following steps |
| 122 | * Open the [wikitr:/Help/Dialog/MapPaint Map Paint Styles Dialog] |
| 123 | * Right click on a style |
| 124 | * Choose Info |
| 125 | * Click on Source Tab |
| 126 | * Search for `version:` at the beginning of the source code |
110 | | [[Image(Mappaint_no_icon.png)]] missing icon[[br]] |
111 | | We don't have the right icon for every node tag in map features yet, e.g. icons for most {{{natural=*}}} tags are still missing. If you encounter such a "missing icon", feel free to create a nice 16*16 pixel icon that matches the tag. To submit your work, open a [/newticket new ticket] and add your image or zip archive as attachment. |
| 140 | [[Image(Mappaint_no_icon.png,margin-right=5,link=)]] missing icon \\ |
| 141 | We don't have the right icon for every node tag in map features yet, e.g. icons for most `natural=*` tags are still missing. If you encounter such a "missing icon", feel free to create a nice 16*16 pixel icon that matches the tag. To submit your work, open a [/newticket new ticket] and add your image or zip archive as attachment. |
131 | | * {{{mappaint.showicons}}} |
132 | | * select whether icons are shown - same values as {{{mappaint.fillareas}}} |
133 | | * {{{mappaint.shownames}}} |
134 | | * select whether names are shown - same values as {{{mappaint.fillareas}}} |
135 | | * {{{mappaint.strokes}}} |
136 | | * select whether strokes or full lines are used - same values as {{{mappaint.fillareas}}} |
137 | | * {{{mappaint.useRealWidth}}} |
138 | | * true - ways will change width corresponding to the real width in meters set in the elemstyle.xml file |
139 | | * false (default) - ways will have the same width on every zoom level |
140 | | * {{{mappaint.zoomLevelDisplay}}} |
| 163 | * `mappaint.showicons` |
| 164 | * select whether icons are shown - same values as `mappaint.fillareas` |
| 165 | * `mappaint.shownames` |
| 166 | * select whether names are shown - same values as `mappaint.fillareas` |
| 167 | * `mappaint.strokes` |
| 168 | * select whether strokes or full lines are used - same values as `mappaint.fillareas` |
| 169 | * ~~`mappaint.useRealWidth`~~ |
| 170 | * ~~true - ways will change width corresponding to the real width in meters set in the elemstyle.xml file~~ |
| 171 | * ~~false (default) - ways will have the same width on every zoom level~~ |
| 172 | * `mappaint.zoomLevelDisplay` |