Olivier Teulière
54736b211a
Moved some code to static methods, so that it can be reused more easily.
2012-01-19 21:20:03 +01:00
Olivier Teulière
cfdf5a928d
Group all the custom validators in a factory class.
...
This will make it easier to factorize and reuse this code.
2012-01-19 15:19:11 +01:00
Olivier Teulière
855718c6b8
Factorized code
2012-01-19 13:17:08 +01:00
Olivier Teulière
eadac39a09
Removed a useless include
2012-01-19 11:47:39 +01:00
Olivier Teulière
a899df5e46
The Training widget is not in a tab anymore
2012-01-19 11:18:23 +01:00
Olivier Teulière
50b55fb7f0
Create the players and scores widgets only when a new game is started.
2012-01-19 10:43:31 +01:00
Olivier Teulière
fbb34d795c
The history now shows the "Player" column only in FreeGame mode.
...
It doesn't really make sense (or it is useless) in the other modes.
2012-01-17 21:45:31 +01:00
Olivier Teulière
7fd8a245f8
Do not refresh the coordinates for a non-visible player.
...
This fixes a focus bug, and makes it easier to enter moves for several
human players.
2012-01-17 10:48:36 +01:00
Olivier Teulière
c81df46b5e
Added a new type of move: NO_MOVE
2012-01-17 00:56:02 +01:00
Olivier Teulière
482b5d674f
Previewing a Round is now possible in all the game types.
...
It was only possible in Training mode. This change will be useful for
the future arbitration mdoe.
2012-01-17 00:43:19 +01:00
Olivier Teulière
219b99192d
Warn before exiting Eliot when a game is started
2012-01-05 21:08:54 +01:00
Olivier Teulière
7883aab6b5
Removed a useless name
2012-01-05 20:44:44 +01:00
Olivier Teulière
5dc491d887
New preference to define a default AI level
2011-12-30 19:33:48 +01:00
Olivier Teulière
9dfed9c51d
Fixed a dictionary creation bug on Win32 with input files containing a BOM.
...
The bug was not showing on Wine, only on Windows itself.
2011-12-30 15:12:26 +01:00
Olivier Teulière
9aea22d968
Use an enum for the variants
2011-08-28 19:25:26 +02:00
Olivier Teulière
56b66fea28
Added setters to GameParams, to simplify the code a little
2011-08-28 19:25:26 +02:00
Olivier Teulière
17bdd27899
Moved the dictionary to the GameParams class
2011-08-28 19:25:26 +02:00
Olivier Teulière
408c92df42
Moved the game mode to the GameParams class
2011-08-28 19:25:26 +02:00
Olivier Teulière
d6fbd6bef1
Allow combining several variants in a single game
2011-08-28 18:47:25 +02:00
Olivier Teulière
e9a49a87ab
Use radio buttons for the game type instead of a combo box
2011-08-27 21:55:49 +02:00
Olivier Teulière
fdc29871e5
New GameParams class to wrap a few game characteristics.
...
These characteristics will not change during the game.
2011-08-27 21:55:49 +02:00
Olivier Teulière
f9a7307898
Added a unit test for all the string conversions
2011-07-30 19:49:29 +00:00
Olivier Teulière
03d93c9360
Renamed the string conversion macros, to make chaining more natural.
2011-07-30 19:45:18 +00:00
Olivier Teulière
cbaad7ff6c
Compilation fixes for the Windows build
2011-07-30 13:15:52 +00:00
Olivier Teulière
08516b07d7
Added support for definitions, using an external website
2011-07-28 20:55:48 +00:00
Olivier Teulière
c8305a0b10
Allow very thin columns
2011-07-17 09:16:52 +00:00
Olivier Teulière
77827bee1a
Added a context menu to the tree header in training mode, to disable automatic resizing of the columns
2011-07-17 09:09:47 +00:00
Olivier Teulière
424fd3af32
Display the points of the word entered by the player before validating it.
2011-07-16 23:31:17 +00:00
Olivier Teulière
23771f3f71
Indicate the end of the game
2011-01-30 00:23:45 +00:00
Olivier Teulière
0c76b9d781
Simplified the looging macros, and added logs in various key places.
2011-01-29 23:47:20 +00:00
Olivier Teulière
e175a6d8bc
Added a new (optional) dependency on log4cxx, to enable logging.
...
If disabled (the default), everything is compiled away.
2011-01-16 21:30:30 +00:00
Olivier Teulière
9ad384eae1
Make sure the board is cleared when a game stops
2011-01-15 21:47:42 +00:00
Olivier Teulière
15da522038
The changed letters are now displayed in upper case
2011-01-15 16:42:20 +00:00
Olivier Teulière
9e4d196d70
Fixed a typo
2011-01-15 16:35:36 +00:00
Olivier Teulière
bbb0ee4510
In free game mode, the "Change" button cannot be used anymore to pass without changing any letter.
...
This should be more intuitive.
2011-01-15 16:33:02 +00:00
Olivier Teulière
6f4c575eb6
Improved error messages when changing letters and/or passing
2011-01-10 22:06:10 +00:00
Olivier Teulière
af37443fc0
New bag widget, showing the remaining tiles. Not used for real yet.
2010-11-01 17:49:55 +00:00
Olivier Teulière
1374304ff9
Moved the tiles layout to a dedicated file
2010-10-22 17:01:31 +00:00
Olivier Teulière
6bf27a4509
Layout improvements:
...
- Handle the minimum size of the layout correctly
- Draw the lines between tiles, instead of drawing on them
2010-10-22 16:59:43 +00:00
Olivier Teulière
3352337142
Let the TileWidget class handle mouse clicks, instead of doing it in the BoardWidget class
2010-10-22 16:58:37 +00:00
Olivier Teulière
cbc6215967
Handle arrows again
2010-10-22 16:57:59 +00:00
Olivier Teulière
e5eb6dd654
Draw an outline around the arrow
2010-10-22 16:57:13 +00:00
Olivier Teulière
308e609966
Display the letters correctly
2010-10-22 16:56:32 +00:00
Olivier Teulière
90027c3210
Display the coordinates of the board, and draw a square around it.
...
It now looks exactly like the old board (with 1 pixel difference for the coordinates, making it better).
2010-10-17 21:45:10 +00:00
Olivier Teulière
858b3997ae
New TileWidget class, to handle a single square
2010-10-17 21:28:01 +00:00
Olivier Teulière
84b69e8919
Ask for a confirmation before starting a new game
2010-10-17 21:24:18 +00:00
Olivier Teulière
c3785555b9
Print to stderr the complete stack trace in case of exception or segmentation fault.
...
This feature will only be activated in debug mode, and if available on the platform.
The symbols will even be demangled if possible (i.e. if compiled with g++).
2010-10-17 21:23:39 +00:00
Olivier Teulière
5cb6ad38cd
New button on the "Dic. info" tab, to save the dictionary words list to a file
2010-09-18 13:07:39 +00:00
Olivier Teulière
31922c8da9
Display the number of remaining vowels, consonants and jokers in the bag window
2010-09-12 15:27:38 +00:00
Olivier Teulière
809eb9eb94
Alternate row colors to make the results table a bit nicer
2010-07-11 20:59:05 +00:00
Olivier Teulière
3608c76fa4
Display for each result the difference with the top score
2010-07-11 20:58:41 +00:00
Olivier Teulière
9c0ca5835a
Force the sort column when refreshing the results
2010-07-11 20:58:21 +00:00
Olivier Teulière
f74e762ee3
Color in red the line if the word corresponds to the best score
2010-07-11 20:58:03 +00:00
Olivier Teulière
d3df401664
Compilation fix for the Windows build
2010-05-19 19:28:09 +00:00
Olivier Teulière
81809dd74f
- Changed a few strings
...
- Updated the po files
- Completed the French translation
2010-05-16 18:12:54 +00:00
Olivier Teulière
32a252c96b
Fixed a bug and added a sanity checks (no duplicate entries in the word list)
2010-05-16 10:05:09 +00:00
Olivier Teulière
80ca8844d9
Generate the dictionary from the wizard, and (optinally) load it.
...
The wizard is now fully usable.
2010-05-15 12:20:19 +00:00
Olivier Teulière
7cf6e90303
New wizard, for creating a dictionary from the GUI.
...
The wizard is almost ready... except that the dictionary is not generated yet!
2010-05-15 12:13:35 +00:00
Olivier Teulière
3666b89337
Do not distribute moc files.
...
Problem reported by Julien Catalano.
2010-05-12 22:12:31 +00:00
Olivier Teulière
8a1897db7a
Mark a string as translatable
2010-03-09 22:32:09 +00:00
Olivier Teulière
b7fff8b4a1
- Removed various C-style casts
...
- Factorized code in the Bag class
2010-03-06 16:54:20 +00:00
Olivier Teulière
2268f4ce0b
Force the gettext() messages to be in UTF-8, because I don't know how to
...
detect properly the correct encoding on Mac OS X when the LANG variable
is not set...
2010-02-12 18:16:57 +00:00
Olivier Teulière
f42398e714
Workaround encoding issues on Mac OS X: when Eliot is started from the dock, the LANG variable is not set. So retrieve the language from the preferences, and force encoding to UTF-8.
2010-02-07 17:34:59 +00:00
Olivier Teulière
57d083cedf
Fixed a macro used to translate text from the .ui files
2010-02-07 17:34:34 +00:00
Olivier Teulière
6981cd18c2
Changed copyright year
2010-01-30 10:30:08 +00:00
Olivier Teulière
eb9f7bb8d5
On Mac, retrieve the locales in the bundle
2010-01-29 21:11:44 +00:00
Olivier Teulière
14ce195e83
One more encoding fix. Hopefully the last one.
2010-01-24 00:53:21 +00:00
Olivier Teulière
41b0d38c8f
Fixed encoding bugs for good, this time.
2010-01-23 23:34:48 +00:00
Olivier Teulière
51b0197afd
Make the code more robust by catching std::exception instead of only GameException
2010-01-23 23:34:23 +00:00
Olivier Teulière
5e3a3b4ceb
Fixed an encoding issue occurring on Windows when Qt is compiled without STL compatibility
2010-01-04 20:19:34 +00:00
Olivier Teulière
99573edcc4
Improved some strings
2010-01-02 11:30:20 +00:00
Olivier Teulière
854733fed2
Fixed a typo
2009-12-06 00:10:29 +00:00
Olivier Teulière
2eb28d61c5
Use expat instead of libxml2: it is much smaller, and is easier to use with Arabica when cross-compiling for Windows
2009-12-06 00:07:35 +00:00
Olivier Teulière
3c7a84d543
Support saving/loading games (any game type) in XML format.
...
Status:
It works well, but there are still a few details to improve/fix
More details about the changes:
- New dependency on Arabica and Libxml2 to parse the XML
- Loading the old format is still supported for this release, but won't be supported anymore in the next one
- Games are now only saved in the new format
- In training mode, the player is now created externally, like in the other modes
- Avoid using GameIO (the one from game/) whenever possible
- Do not use a FILE* argument anymore when loading a game
- Throw and catch exceptions correctly when a game cannot be loaded or saved
- The non-regression tests now use a new method to print the game history
2009-11-29 16:01:31 +00:00
Olivier Teulière
eb22343932
Added a missing translation
2009-10-23 20:19:04 +00:00
Olivier Teulière
43d42a0388
Little hack to have the 7+1 search in alphabetical order (or more precisely, in the order of the letters as defined at dictionary creation)
2009-09-21 20:10:34 +00:00
Olivier Teulière
02e4cb2970
- Invalid moves should be in the display form
...
- Moved some code from Header to Dictionary
2009-07-03 21:40:14 +00:00
Olivier Teulière
8485e317b5
- Improved some strings
...
- Update of the French translation
- Fixed make distcheck (compdic.cpp contains non-ascii chars)
2009-06-28 12:11:10 +00:00
Olivier Teulière
e42bc55965
Display the alternative inputs in the dictionary information tab
2009-06-28 11:47:50 +00:00
Olivier Teulière
0e9711da25
Accept various inputs for the same tile in the Qt interface.
...
The dictionary format still needs to support that.
2009-06-27 18:09:44 +00:00
Olivier Teulière
3a4daa844b
Fixed tab order on the player widget
2009-06-26 21:27:13 +00:00
Olivier Teulière
adda457672
Use the display strings also when verifying a word and when listing the dictionary letters
2009-06-23 17:07:17 +00:00
Olivier Teulière
47e4b8c6b0
Simplifications
2009-06-23 12:56:40 +00:00
Olivier Teulière
7569a58bb7
Each letter (tile) now has a display string, defaulting to its internal char. It is not yet possible to change it.
...
This display string is used in the ncurses and Qt interfaces.
Display strings are types "wdstring" instead of plain "wstring" in a few places (not all of them) to help recognize them.
2009-06-23 12:41:53 +00:00
Olivier Teulière
4d86e236e0
- Fixed an accelerator key in the English version
...
- Added a reference to the web site in the About box
- Fixed an encoding problem on an error message
- Explained better the error message saying to select a dictionary
2009-02-28 09:24:27 +00:00
Olivier Teulière
2ced8b3131
Changed slightly the behaviour of the coordinates arrow on a left click
2009-02-21 16:53:18 +00:00
Olivier Teulière
c6a799b24d
Update of the French translation
2009-02-19 21:56:41 +00:00
Olivier Teulière
ed2a20a3e3
- Allow setting the coordinates of the played word by clicking on the board
...
- New PlayWordMediator class, to encapsulate the behaviour of the controls
used to play a word
- The Training mode now has input fields to play words directly, without
choosing them in the search results
2009-02-19 18:25:17 +00:00
Olivier Teulière
8f72fd8152
- Always display characters in uppercase on the board (a lowercase character was still possible with a joker, in some rare cases)
...
- Fixed a compilation warning
2009-01-26 20:30:41 +00:00
Olivier Teulière
1df3c3ff51
Updated a few copyright dates
2009-01-24 17:44:56 +00:00
Olivier Teulière
7a5056354a
- Setting the rack manually is now done via a command, and can thus be undone
...
- Added non-regression tests for the navigation in the game history (all modes), and removed a less useful test
2009-01-24 10:28:20 +00:00
Olivier Teulière
e085384e2f
- Do not save the splitter position when no game is playing, because the position is not relevant without the players group
...
- Updated the French translation
2009-01-22 21:41:27 +00:00
Olivier Teulière
87e1d4795b
Sorting the search results happens to be quite slow, often much slower than the search itself.
...
But we don't need to sort them all the time, and in general we don't even need to keep all the rounds.
This commit greatly improves the search performance by filtering the results in 3 different ways, depending on the context:
- A limit to the number of results can be given (useful for the training mode). The kept results are the best ones, not the first ones found by the search.
- When only the best round is needed (when the AI is playing with level 100, or when preparing the rack for an explosive game), we don't need to keep rounds with a lower score
- When the AI has a level lower than 100, it is still possible to skip many rounds
The search limit in training mode is configurable (defaulting to 100) and can be deactivated.
2009-01-22 18:30:22 +00:00
Olivier Teulière
e83e4dcc99
- Use splitters to allow the user to resize freely the components of the main window
...
- Save splitters positions from one session to the next
- Fixed default focus issues introduced in the previous commit
2009-01-15 20:22:11 +00:00
Olivier Teulière
d913be52a0
Support explosive games in the Qt interface
2009-01-15 18:33:32 +00:00
Olivier Teulière
229f1fcc14
- Removed the RACK_MANUAL enum value, and the obsolete Training::setRack() method
...
- qt/board_widget.cpp: cosmetics
2009-01-11 14:20:35 +00:00
Olivier Teulière
a4ae71d55d
- TODO update
...
- Allow displaying letter points on the board with an option (on by default)
- Fixed the tab order on the preferences window
- Improved the behaviour and default size of the preferences window
2009-01-04 17:39:27 +00:00
Olivier Teulière
6a2eca1db1
New icons for the navigation actions, and additional ones for some menu items
2008-12-14 13:27:00 +00:00
Olivier Teulière
0e08cccd41
New preference, to allow linking the rack in training mode to the "Plus 1" dictionary tool
2008-12-14 13:20:38 +00:00
Olivier Teulière
97157b1716
Save the toolbar visibility from one session to the next
2008-12-08 21:38:12 +00:00