Changes between Version 20 and Version 21 of Help/Styles/MapCSSImplementation
- Timestamp:
- 2013-02-07T19:21:26+01:00 (12 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Help/Styles/MapCSSImplementation
v20 v21 1 This page documents details on JOSM's [http://wiki.openstreetmap.org/wiki/MapCSS/0.2 MapCSS] implementation. At the moment (May-2012) it is under active development and anything may change without warning.1 This page documents details on JOSM's [http://wiki.openstreetmap.org/wiki/MapCSS/0.2 MapCSS] implementation. 2 2 [[TOC(inline)]] 3 3 == General Structure == … … 758 758 list(a, b, ...):: 759 759 create list of values, e.g. for the {{{dashes}}} property 760 get(lst, n):: 761 get the ''n''th element of the list ''lst'' (counting starts at 0) [''since 5699''] 762 split(sep, str):: 763 splits string ''str'' at occurrences of the separator string ''sep'', returns a list [''since 5699''] 760 764 prop(''p_name''):: 761 765 value of the property ''p_name'', e.g. prop({{{"width"}}}) … … 778 782 length(''str''):: 779 783 length of a string 784 length(''lst''):: 785 length of a list [''since 5699''] 780 786 concat(''str1'', ''str2'', ...):: 781 787 assemble the strings to one 782 788 JOSM_search("..."):: 783 789 true, if JOSM search applies to the object 790 regexp_test(regexp, string):: 791 test if ''string'' matches pattern ''regexp'' [''since 5699''] 792 regexp_test(regexp, string, flags):: 793 test if ''string'' matches pattern ''regexp''; flags is a string that may contain "i" (case insensitive), "m" (multiline) and "s" (dot all) [''since 5699''] 794 regexp_match(regexp, string):: 795 tries to match ''string'' against pattern ''regexp''; returns a list of capture groups in case of success, ''null'' otherwise [''since 5699''] 796 regexp_match(regexp, string, flags):: 797 tries to match ''string'' against pattern ''regexp''; returns a list of capture groups in case of success, ''null'' otherwise; flags is a string that may contain "i" (case insensitive), "m" (multiline) and "s" (dot all) [''since 5699''] 798 osm_id():: 799 returns the OSM id of the current object [''since 5699''] 784 800 {{{#!comment: untested 785 801 JOSM_pref(''key'', ''default'')