61815 Commits

Author SHA1 Message Date
Charles Dang
17d1212a0e General wmlindent run 2015-08-12 17:10:09 +11:00
Charles Dang
730453cf01 LoW S3: fixed pesky comment line preventing wmlindent from affecting file 2015-08-12 16:48:45 +11:00
Charles Dang
2f650419da Cleaned up old code related to border_size, usage, and map header 2015-08-12 16:32:35 +11:00
Charles Dang
6b78073b49 Don't pass border_size and usage to gamemap::read
This also fixes an issue in [terrain_mask] where masks would be incorrectly
offset due to a default border_size of 0
2015-08-12 16:32:32 +11:00
aquileia
5cf8cf2b32 vcproj: Fix File node from PR #447 2015-08-12 00:29:13 +02:00
Charles Dang
8adbae8da1 LoW: dropped commas before chapter titles 2015-08-12 07:29:42 +11:00
Charles Dang
768a418137 Deprecate ON_SIGHTING
Since sighted events now work, this macro is no longer necessary
2015-08-12 06:12:13 +11:00
Elvish_Hunter
f099638b26 wmllint: replaced backticks with repr()
Backticks as shortcut for repr() are removed from Python 3. Although all their usages were already commented out, I fixed it anyway in case the code is uncommented.
2015-08-11 19:41:37 +02:00
Elvish_Hunter
d8478cbed1 wmllint: replaced map and string.strip with list comprehension
string.strip() isn't available on Python 3, because of its redundancy with the .strip() method available on any string.
2015-08-11 19:41:37 +02:00
Elvish_Hunter
7fa2943683 All main WML tools: replaced tabs with spaces 2015-08-11 19:41:36 +02:00
Charles Dang
ad881b5d0b Formatting fixup for 08d5d9c8e8a1 2015-08-12 03:21:23 +11:00
aquileia
08d5d9c8e8 Add nightblade unit description 2015-08-11 18:16:46 +02:00
Ignacio R. Morelle
b9c6ab59d6 Fix WML variable leak in RECRUIT_UNIT_VARIATIONS 2015-08-09 01:52:27 -03:00
Charles Dang
cd50036363 Restore a check to prevent portrait-less units from using a scaled sprite instead 2015-08-09 14:42:28 +11:00
gfgtdf
cd0b12387b better error message 2015-08-09 03:38:24 +02:00
Elvish_Hunter
de64146e35 wmllint, wmltools and wmliterator: more Python 3 compatibility stuff
'raw_input' and 'xrange' in Python 3 are renamed respectively 'input' and 'range'.
2015-08-08 20:36:53 +02:00
Elvish_Hunter
b892f764a6 wmlscope: try to make the image size checks more useful 2015-08-08 20:36:53 +02:00
gfgtdf
de1eaa30f7 Use listboxs sorting feature in experinemtal gui2 addon_list
Also fixes the toggle panels that show the addons description and the filter
textbox in the non new-widgets codepath.

These changes mostly effect the non new-wigets codepath. The new-widgets
codepath (which already had a sorting feature) still works like before
except that it was adjusted to the changes to the cfg file.
2015-08-08 16:33:08 +02:00
Ignacio R. Morelle
32342a5fc4 gui2/tlabel_settings: Exclude from GUI2 unit test
The dialog is not tested currently, which causes the GUI2 unit test to
fail (imagine that). Since the class constructor requires a hefty amount
of fluff to work (in particular, a display_context object), might as
well just disable it for the time being.
2015-08-08 03:08:29 -03:00
Ignacio R. Morelle
74a81069b9 Merge pull request #447 from CelticMinstrel/master
Interface to fine-tune displayed labels (and some other label stuff)
2015-08-08 01:29:15 -03:00
Celtic Minstrel
f619b4cc63 Update build stuff
(Sconscript, CMakeLists, tests, project files)
2015-08-07 22:50:34 -04:00
Celtic Minstrel
e130a960cb Update credits and changelog 2015-08-07 22:50:24 -04:00
aquileia
79b7bf1777 Windows Installer: Update icons 2015-08-08 04:24:01 +02:00
aquileia
d8b5e7b3c1 Windows installer: Remove userdata dir selection
Due to UAC, especially virtualization of the Programs directory, it is preferable to force 'My Games' as the location.
2015-08-08 03:53:05 +02:00
aquileia
c7ffe8dfd7 Windows installer: Update to NSIS 3
Compatibility changes:
- Plugins moved to a different directory

New Features:
- Unicode installer
- Could now detect Windows 8 - 10
2015-08-08 03:53:05 +02:00
aquileia
4a272b301d Windows installer: Use FILE /oname to avoid copying files 2015-08-08 03:53:04 +02:00
aquileia
1c3fa278ff Windows installer: Cut down on shortcuts
From the impressive number of 9 start menu shortcuts, 2 were removed.

An additional 4 were removed for Windows 8, where the app list can't collapse folders.
2015-08-08 03:53:04 +02:00
aquileia
12066d87c5 Windows Installer: Translate 'Battle for Wesnoth' and shortcuts
The title is now localized, as are the start menu shortcuts. As localized
titles can be longer than the English string, a third line was explicitly
added to the welcome page (else NSIS cuts the line in half).

The manual shortcut points to the translated manual version, if available.

Due to lack of Unicode support in NSIS 2, only translations matching the
codepage are displayed correctly.

The desktop.ini file isn't removed during uninstallation as it may contain
info on other programs, e.g. if the player chose to place the shortcuts in
'Games'.
2015-08-08 03:53:04 +02:00
aquileia
46af40eb61 Windows Installer: Add GPL translations
Source:
https://www.gnu.org/licenses/old-licenses/gpl-2.0-translations.html
http://www.gnu.org/licenses/translations.html

Changes:
- Links to the English original added in the headers.
- Portuguese translations reindented to fit width of textbox.
- Reference between Chinese GPLs removed.
- UTF8 BOM added (else NSIS doesn't recognize the encoding).

Thanks to @chisquare130 (Xara) for checking the Chinese versions.
2015-08-08 03:53:03 +02:00
aquileia
01dfc6783f Windows installer: Remove components page
We only have one module anyways, thus there's no choice in the component selection menu.
2015-08-08 03:53:03 +02:00
Celtic Minstrel
d657c30a50 Labels from players in your ignore list default to hidden 2015-08-07 19:24:07 -04:00
Celtic Minstrel
af3eae9d0b Assign a label category to village names 2015-08-07 18:54:25 -04:00
Celtic Minstrel
e2a0648a15 Use team colors for player label categories 2015-08-07 18:54:13 -04:00
Celtic Minstrel
819eab2f96 Add dialog to allow user to customize which label groups are displayed 2015-08-07 16:44:50 -04:00
gfgtdf
d87b8457ed Merge pull request #446 from gfgtdf/sortable_listbox
sortable gui2 listboxes
2015-08-07 13:52:20 +02:00
gfgtdf
a4806343f5 sortable listboxes for gui2
Fixes http://gna.org/bugs/index.php?23751

Gui2 listboxes can now be sorted. As an example how to use it i changed the
gui2 loadgame dialog to use this new feature.

To make your listbox sortable you have to add togglebuttons/panels with the
id sort_n where n is a number in [0, numer_of_columns) to the [header] of
the listbox, then the listbox will be sorted when a user clicks on that
togglebutton/panel. Also you have to register the comparision functions for
each column with listbox::set_column_order.

Alternatively you can sort the listbox manually by calling listbox::order_by

This feautre still suffers from http://gna.org/bugs/?15763 . But for small
listboxes without scrollbars this is already a good feature.
2015-08-07 13:02:28 +02:00
gfgtdf
1359e6a885 tristate buttons for gui2
This commit adds the c++ code to add tristate buttons: toggle_buttons and
toggle_panels can now have an arbitrary number of states instead of just 2
(selected and not selected). The number of states is determined by the number
of [state] tags in the widgets definition.

This doesn't add tristate definitions yet, but the plan is to use tristate
buttons later for the headers of sortable lists (No-Sort, Sort-Up, Sort-Down
buttons)

TODO: figure out whether to remove the parameter from tcontrols constructor.
2015-08-07 13:00:49 +02:00
Celtic Minstrel
1c578590e1 Add sliders to set colour of label in map editor
- Needs work, not very user-friendly in my opinion
2015-08-06 23:43:16 -04:00
Celtic Minstrel
af6d3060e2 Add new "category" and "creator" properties to map labels
- The "category" property is mainly for use by scenario designers; players will be able to hide labels based on this
- The "creator" property is meant to allow players to hide labels placed by specific other players
- Map editor allows setting the "category" property
2015-08-06 23:27:11 -04:00
Elvish_Hunter
2559f97063 wmlscope: slightly improved percentage output when checking for untyped formals 2015-08-07 00:06:54 +02:00
Elvish_Hunter
63863d9f2f wmlscope: enabled image size checks
The undersized() function is supposed to warn if an image has a size below 60 x 60 pixels. I didn't manage to find any documentation about why it was commented out.
I also replaced the error message printed if the PIL library is missing with one more verbose and updated.
2015-08-07 00:04:34 +02:00
Elvish_Hunter
4d675c377f All main wml tools: used Python 3 floating point division
wmltools required integer division, so here the corresponding operator (//) is used
2015-08-06 23:49:40 +02:00
Elvish_Hunter
be62976d80 wmltools and wmlscope: fixed .keys() usages for Python 3
Most usages of the .keys() method were already safe, because they were either iterated only once, or they were wrapped in a call to sorted(), which casts them as lists
2015-08-06 23:40:48 +02:00
Elvish_Hunter
c407625ad3 wmllint: fixed .keys() usages for Python 3
In most cases, calls to the .keys() method were unnecessary, because they were used to test if a dictionary has a key; this can be done by simply using the 'in' operator on the dictionary itself.
2015-08-06 23:33:59 +02:00
Elvish_Hunter
032609e782 wmlscope: clearer message when checking for duplicated files
For now, I'm keeping the MD5 hashes in the message.
2015-08-06 23:21:20 +02:00
Elvish_Hunter
bb51399d26 wmltools: shorten code by using sorted() instead of .sort() 2015-08-06 23:16:48 +02:00
Elvish_Hunter
889eb5aa7b wmllint: fixed a bug in spellchecking caused by Python 3 map()
This bug prevented local spelling words from being added to the spellchecking dictionary, and it was caused by the fact that the map iterator was never iterated.
Replaced with an explicit for cycle.
2015-08-06 23:13:47 +02:00
gfgtdf
6cc2c93853 Better errormessage when failing to read schema.cfg 2015-08-06 15:03:32 +02:00
aquileia
4e4fdd0504 manual: Clean up localized files
Also, apply two commits for the LoW map overlays that were only committed
to 1.12.
2015-08-06 15:01:41 +02:00
Elvish_Hunter
6c4ceacb00 wmlscope: fixed a copy-pasting error 2015-08-05 22:13:10 +02:00