Warning, /frameworks/syntax-highlighting/autotests/input/test.pbl is written in an unsupported language. File is not indexed.
0001 # Wesnoth Markup Language 0002 0003 #textdomain wesnoth-libs 0004 0005 #define __GUI_WINDOW_HEIGHT 0006 ( 0007 if(window_height = 0, 9999, window_height) 0008 )#enddef 0009 0010 #define __GUI_WINDOW_FUNCTIONS 0011 def reevaluate_best_size(w, s) 0012 ( 0013 [ 0014 0, 0015 # 0016 debug_print('window ', w), 0017 debug_print('screen ', s) 0018 # 0019 ][0] 0020 ); 0021 #enddef 0022 0023 # Don't highlight array indices as tags 0024 stored_unit[1].moves 0025 other[0][1][2] 0026 other[foo][bar] 0027 0028 foo[{MACRO}] 0029 foo[$index] 0030 foo[ 12 ] 0031 0032 # Nested tags 0033 [allow_undo][/allow_undo][not][true]text[/true][/not] 0034 [foo][bar]text[/bar][/foo] 0035 0036 [about] 0037 title= _ "Campaign Designer" 0038 text="Your Name" 0039 [/about] 0040 0041 [window] 0042 id = "tooltip" 0043 0044 [resolution] 0045 definition = "tooltip" 0046 automatic_placement = false 0047 functions = "{__GUI_WINDOW_FUNCTIONS}" 0048 0049 [grid] 0050 0051 [row] 0052 0053 [column] 0054 0055 [label] 0056 id = "label" 0057 definition = "default_small" 0058 0059 use_markup = true 0060 wrap = true 0061 [/label] 0062 0063 [/column] 0064 0065 [/row] 0066 0067 [/grid] 0068 0069 [/resolution] 0070 0071 [/window] 0072 0073 [event] 0074 name = preload 0075 first_time_only = no 0076 [lua] 0077 code = << 0078 function narrator(t) 0079 -- Behave like the [message] tag. 0080 wesnoth.fire("message", 0081 { speaker = "narrator", message = t.sentence }) 0082 end 0083 >> 0084 [/lua] 0085 [/event] 0086 0087 [event] 0088 name = turn 1 0089 [lua] 0090 code = << narrator(...) >> 0091 [args] 0092 sentence = _ "Hello world!" 0093 [/args] 0094 [/lua] 0095 [lua] 0096 code = << narrator(...) >> 0097 [args] 0098 sentence = _ "How are you today?" 0099 [/args] 0100 [/lua] 0101 [/event]