2096 Commits

Author SHA1 Message Date
Elvish_Hunter
9b1262acc6 Converted imgcheck to Python 3
This commit also fixes the Pillow library not being imported correctly, which prevented the script from running at all, and slightly reformats the output.
2015-12-20 21:46:25 +01:00
Ignacio R. Morelle
3821b7c416 Remove macro-reference.html on clean target 2015-12-16 15:24:29 -03:00
Ignacio R. Morelle
1aaa341e35 wmllint: Ignore id in [trait] for unit id checks 2015-11-06 00:09:34 -03:00
Ignacio R. Morelle
ba8da92135 Restore executable bit on the WML tools GUI frontend 2015-10-30 02:43:35 -03:00
Ignacio R. Morelle
851eddfd5e Restore executable bit on WML tools 2015-10-30 02:43:02 -03:00
Elvish_Hunter
e07de1bf48 GUI.pyw: fixed regexps not being handled correctly on non Windows systems
This fix relies on the fact that argparse doesn't require the equal sign any more.
2015-10-20 15:02:32 +02:00
Elvish_Hunter
491ba7924f wmlindent: upgrade from optparse to argparse 2015-10-20 15:02:32 +02:00
Elvish_Hunter
2d4ef7a42d wmlscope: upgrade from optparse to argparse 2015-10-20 15:02:32 +02:00
Elvish_Hunter
42ac2e0fe7 wmllint: upgrade from optparse to argparse
This has two advantages: first, it enforces a help style which is consistent across the various tools; second, it makes easier adding new command line options.
Another interesting fact is that those options requiring additional parameters do not need the equal sign any more; that is, writing --foo=bar is now the same as writing --foo bar.
2015-10-20 15:02:32 +02:00
Elvish_Hunter
1a0d04d7b2 GUI.pyw: fixed a bug that caused the output to not be printed on Windows 2015-10-20 15:02:32 +02:00
Elias Pschernig
b742542b37 [wesnoth_addon_manager] Speedup writing files to disk *a lot* :) 2015-10-05 17:36:46 -04:00
Elias Pschernig
ed83c6b888 [wesnoth_addon_manager] fixed an error message 2015-10-05 10:55:19 -04:00
Elvish_Hunter
6e4ecbb408 Converted wmllint-1.4 to Python 3 2015-09-24 11:40:14 +02:00
Elvish_Hunter
21a6bc5831 Converted GUI.pyw to Python 3 2015-09-24 11:40:14 +02:00
Elvish_Hunter
526d745dfb Converted wmlindent to Python 3 2015-09-24 11:40:13 +02:00
Elvish_Hunter
1f5d713ee1 Converted wmlscope to Python 3 2015-09-24 11:40:13 +02:00
Elvish_Hunter
a04bc6f45d Converted wmllint to Python 3
Please note that attempting to run wmllint on Python 3.4 leads to an exception after finishing the spellcheck. This is a known bug in PyEnchant 1.6.5, and it can be solved by using PyEnchant 1.6.6.
See https://github.com/rfk/pyenchant/issues/34 .
2015-09-24 11:40:13 +02:00
Elvish_Hunter
53b5d031e9 Added Python 3 versions of wmltools and wmliterator
The Python 2 versions should be removed as soon as there are no more scripts using them.
2015-09-24 11:40:13 +02:00
Elias Pschernig
900c84657b Upgraded wesnoth_addon_manager to Python 3
This includes campaignserver_client.py which is also used by wescamp.py
- however wescamp.py is still Python 2 at this point and will need to be
  upgraded at a later point in time.
2015-09-22 16:33:14 -04:00
Elias Pschernig
4c034d7705 Clean up wmlparser3.py a bit, fix json and xml output. 2015-09-20 14:53:49 -04:00
Elvish_Hunter
e39f6376c8 wmllint-1.4: use string formatting or interpolation instead of concatenation 2015-09-20 10:27:37 +02:00
Celtic Minstrel
f54d6b5d28 Rewrite leadership ability as a single macro using $other_unit
Note: It's no longer supported to use the macro in a unit with a non-matching level,
for example giving a 2nd-level unit 4th-level leadership.
2015-09-19 02:14:38 -04:00
Elvish_Hunter
53ee364bab wmllint-1.4: renamed two variables
Used 'r' instead of 'm' if the code refers to ranged attacks (instead of melee); also, ensure that the regexps check the modified versions of the line.
2015-09-16 21:03:34 +02:00
Elvish_Hunter
3afe74b5de wmllint-1.4: renamed a variable
'i' wasn't used in places visible from within the cycle, so using 'j' was pointless.
2015-09-16 21:03:33 +02:00
Elvish_Hunter
f4f11c03fc wmllint-1.4: simplify a line modification 2015-09-16 21:03:33 +02:00
Elvish_Hunter
2877a6a489 wmllint-1.4: use enumerate() to iterate over lines 2015-09-16 21:03:33 +02:00
Elvish_Hunter
ac31185083 wmllint-1.4: use 'with' statement when handling files 2015-09-16 21:03:33 +02:00
Elvish_Hunter
b8dfa190f2 wmllint-1.4: replaced a dict(map()) with dict comprehension 2015-09-12 22:59:18 +02:00
Elvish_Hunter
a12d99e98c wmllint-1.4: use 'x in line' instead of 'line.count(x)' 2015-09-12 21:49:03 +02:00
Elvish_Hunter
91f5bf16c2 wmllint-1.4: use Python 3 range()
That's the function known in Python 2 as xrange().
2015-09-12 21:49:03 +02:00
Elvish_Hunter
1d2944569c wmllint-1.4: open files as UTF-8 and use Unicode literals 2015-09-12 21:49:02 +02:00
Elvish_Hunter
ef559d0ffd GUI.pyw: allow binding tooltips to tagged elements of widgets 2015-09-12 21:49:02 +02:00
Elias Pschernig
f8fb04093a [units.wesnoth.org] fix some small issues 2015-09-10 18:10:16 -04:00
Charles Dang
4f078f26ef GUI.pyw: small label tweaks 2015-09-10 21:55:43 +11:00
Elias Pschernig
3ab3db3166 [units.wesnoth.org] Converted the script to Python 3.
Basically ran all .py files through 2to3. I made a copy of wmlparser2.py
called wmlparser3.py for the Python3 version, so as to not inconvenience anyone
who may be using it in their old Python2 scripts.
2015-09-09 22:52:23 -04:00
Elias Pschernig
00516dddbe [units.wesnoth.org] always clean up error log 2015-09-09 10:30:35 -04:00
Elias Pschernig
2cdcae6294 [wmlunits] fix typo 2015-09-08 21:19:42 -04:00
Elias Pschernig
225234b121 [wmlunits: log used memory for pre-pass] 2015-09-08 20:56:14 -04:00
Elias Pschernig
1961c43f16 [wmlunits] clear <config>/data/add-ons
Sometimes if the last run aborted in the wrong moment, add-ons may keep
left overs in there.
2015-09-08 20:15:37 -04:00
Elvish_Hunter
2e574252cb GUI.pyw: added more tooltips 2015-09-07 20:55:09 +02:00
Elvish_Hunter
814d9d1478 GUI.pyw: allow changing tooltip text at runtime 2015-09-07 20:55:09 +02:00
Elvish_Hunter
3cbbede271 GUI.pyw: use specific tooltip font 2015-09-07 20:55:09 +02:00
Elvish_Hunter
78e03f33f3 wmllint-1.4: removed tabs 2015-09-07 20:55:08 +02:00
Elvish_Hunter
cb3c5b9c45 GUI.pyw: focus doesn't follow the mouse any more
Done as per shadowm's suggestion.
2015-09-03 10:06:14 +02:00
Charles Dang
282cfe38be Added new default amla icon
The old icon (misc/icon-amla-default.png) remains for compatibility purposes,
but I added a wmllint rule to update the path.

The new image was created with https://openclipart.org/detail/29043/heart, which is
released under the public domain (CC-0).
2015-09-03 18:53:11 +11:00
Elvish_Hunter
dce1e7bdc1 GUI.pyw: added tooltips, finally! 2015-09-02 19:52:46 +02:00
Elvish_Hunter
b23e93a823 GUI.pyw: added exit confirmation dialog 2015-08-31 23:12:06 +02:00
Elvish_Hunter
8db92e9af3 wmllint-1.4: replaced backticks with repr() 2015-08-31 22:05:03 +02:00
Elvish_Hunter
2bc6aadd49 wmllint-1.4: map, str and dir are Python internal function
Added underscores to distinguish variable names.
2015-08-30 11:06:22 +02:00
Elvish_Hunter
e5bcb79ac8 wmllint-1.4: used Python 3 filter() and map() 2015-08-30 10:50:56 +02:00