Difference between revisions of "LRM msg Support"
(→Example Project Definition File) |
(→Example Project Definition File) |
||
Line 75: | Line 75: | ||
<!-- <file-location-pattern>resources_LCID</file-location-pattern>--> |
<!-- <file-location-pattern>resources_LCID</file-location-pattern>--> |
||
<resource-extension> |
<resource-extension> |
||
− | <extension>msg</extension> |
+ | '''<extension>msg</extension>''' |
− | <file-name-pattern>*_l_c_v</file-name-pattern> |
+ | '''<file-name-pattern>*_l_c_v</file-name-pattern>''' |
<!--If the base resource files use the file-name-pattern in their name --> |
<!--If the base resource files use the file-name-pattern in their name --> |
||
<!--then set use-pattern-on-dflt-locale to 1, if not then set to 0--> |
<!--then set use-pattern-on-dflt-locale to 1, if not then set to 0--> |
||
− | <use-pattern-on-dflt-locale>0</use-pattern-on-dflt-locale> |
+ | '''<use-pattern-on-dflt-locale>0</use-pattern-on-dflt-locale>''' |
− | <file-location-pattern></file-location-pattern> |
+ | '''<file-location-pattern></file-location-pattern>''' |
<!--If the base resource files use the file-location-pattern in their name --> |
<!--If the base resource files use the file-location-pattern in their name --> |
||
<!--then set use-location-pattern-on-dflt-locale to 1, if not then set to 0--> |
<!--then set use-location-pattern-on-dflt-locale to 1, if not then set to 0--> |
||
− | <use-location-pattern-on-dflt-locale>0</use-location-pattern-on-dflt-locale> |
+ | '''<use-location-pattern-on-dflt-locale>0</use-location-pattern-on-dflt-locale>''' |
− | <base-file-encoding>UTF-8</base-file-encoding> |
+ | '''<base-file-encoding>UTF-8</base-file-encoding>''' |
− | <localized-file-encoding>UTF-8</localized-file-encoding> |
+ | '''<localized-file-encoding>UTF-8</localized-file-encoding>''' |
<!--Default pattern for xml is '![CDATA[%\\d+%|%[ds]]]'--> |
<!--Default pattern for xml is '![CDATA[%\\d+%|%[ds]]]'--> |
||
− | <parameter-regex-pattern><![CDATA[%\\d+%|%[ds]]]></parameter-regex-pattern> |
+ | '''<parameter-regex-pattern><![CDATA[%\\d+%|%[ds]]]></parameter-regex-pattern>''' |
</resource-extension> |
</resource-extension> |
||
<resource-extension> |
<resource-extension> |
||
− | <extension> |
+ | '''<extension>''myext''</extension>''' |
− | <parser-type>msg</parser-type> |
+ | '''''<parser-type>msg</parser-type>''''' |
− | <file-name-pattern>*_l_c_v</file-name-pattern> |
+ | '''<file-name-pattern>*_l_c_v</file-name-pattern>''' |
<!--If the base resource files use the file-name-pattern in their name --> |
<!--If the base resource files use the file-name-pattern in their name --> |
||
<!--then set use-pattern-on-dflt-locale to 1, if not then set to 0--> |
<!--then set use-pattern-on-dflt-locale to 1, if not then set to 0--> |
||
− | <use-pattern-on-dflt-locale>0</use-pattern-on-dflt-locale> |
+ | '''<use-pattern-on-dflt-locale>0</use-pattern-on-dflt-locale>''' |
− | <file-location-pattern></file-location-pattern> |
+ | '''<file-location-pattern></file-location-pattern>''' |
<!--If the base resource files use the file-location-pattern in their name --> |
<!--If the base resource files use the file-location-pattern in their name --> |
||
<!--then set use-location-pattern-on-dflt-locale to 1, if not then set to 0--> |
<!--then set use-location-pattern-on-dflt-locale to 1, if not then set to 0--> |
||
− | <use-location-pattern-on-dflt-locale>0</use-location-pattern-on-dflt-locale> |
+ | '''<use-location-pattern-on-dflt-locale>0</use-location-pattern-on-dflt-locale>''' |
− | <base-file-encoding>UTF-8</base-file-encoding> |
+ | '''<base-file-encoding>UTF-8</base-file-encoding>''' |
− | <localized-file-encoding>UTF-8</localized-file-encoding> |
+ | '''<localized-file-encoding>UTF-8</localized-file-encoding>''' |
<!--Default pattern for xml is '![CDATA[%\\d+%|%[ds]]]'--> |
<!--Default pattern for xml is '![CDATA[%\\d+%|%[ds]]]'--> |
||
− | <parameter-regex-pattern><![CDATA[%\\d+%|%[ds]]]></parameter-regex-pattern> |
+ | '''<parameter-regex-pattern><![CDATA[%\\d+%|%[ds]]]></parameter-regex-pattern>''' |
</resource-extension> |
</resource-extension> |
||
</resource-extensions> |
</resource-extensions> |
Revision as of 19:51, 31 August 2017
Example of .msg files as well as file extensions using the msg parser type
$ A Globalyzer generated message file $set MainSet $ SOURCE_FILE C:/Path/to/my/source/StringBug.hpp STRI_BADLINE_6 "Bad line" STRI_INVALID_7 "Invalid Rectangle" STRI_INVALID_8 "Invalid Color" STRI_INVALID_9 "Invalid Point" STRI_INVALID_10 "Invalid DWORD" STRI_UNRECOG_11 "Unrecognized type" STRI_SLINEDS_12 "%s (line #%d) : %s" STRI_RUNTIME_13 "Runtime Variable Error" STRI_KEYNOTF_14 "Key not found" $ SOURCE_FILE C:/Path/to/my/source/keypressEvents.cxx KEYP_PRESSED_1 "Pressed " KEYP_UP_2 "Up" KEYP_THEUPAR_3 "The up arrow was pressed." KEYP_SHOULDD_4 "Should detect because ignore second issue" KEYP_THEAKEY_5 "The a key was pressed."
Example Project Definition File
<?xml version="1.0" encoding="UTF-8" standalone="no"?> <lrmconf> <model-version>2.0.11</model-version> <project-name>DemoMsg</project-name> <project-desc>This is a sample LRM Project definition file, configured for Msg resource files</project-desc> <group-name>acme</group-name> <top-level-dir>C:\acme\source</top-level-dir> <detect-errors> <missed-trans-error>1</missed-trans-error> <parameter-mismatch-error>1</parameter-mismatch-error> </detect-errors> <track-back-locale>br</track-back-locale> <pseudo-locale>eo</pseudo-locale> <target-locales> <locale>es_MX</locale> <locale>fr_CA</locale> <locale>fr_FR</locale> </target-locales> <default-locale>en_US</default-locale> <resource-extensions> <resource-extension> <extension>msg</extension> <file-name-pattern>*_l_c_v</file-name-pattern> <use-pattern-on-dflt-locale>0</use-pattern-on-dflt-locale> <file-location-pattern></file-location-pattern> <use-location-pattern-on-dflt-locale>0</use-location-pattern-on-dflt-locale> <base-file-encoding>UTF-8</base-file-encoding> <localized-file-encoding>UTF-8</localized-file-encoding> <parameter-regex-pattern><![CDATA[%\\d+%|%[ds]]]></parameter-regex-pattern> </resource-extension> <resource-extension> <extension>myext</extension> <parser-type>msg</parser-type> <file-name-pattern>*_l_c_v</file-name-pattern> <use-pattern-on-dflt-locale>0</use-pattern-on-dflt-locale> <file-location-pattern></file-location-pattern> <use-location-pattern-on-dflt-locale>0</use-location-pattern-on-dflt-locale> <base-file-encoding>UTF-8</base-file-encoding> <localized-file-encoding>UTF-8</localized-file-encoding> <parameter-regex-pattern><![CDATA[%\\d+%|%[ds]]]></parameter-regex-pattern> </resource-extension> </resource-extensions> <dirset> <includes> <include-dir>**/**</include-dir> </includes> <excludes> </excludes> </dirset> </lrmconf>