1
0
Fork 0
mirror of https://github.com/shlomif/PySolFC.git synced 2025-04-05 00:02:29 -04:00
Commit graph

1205 commits

Author SHA1 Message Date
Shlomi Fish
25f1b222a1 fix tidyall/flake8 tests 2020-02-27 19:27:41 +02:00
lufebe16
11aff68af1 Updates kivy version:
- added support for right mouse button (desktop only)
- corrected a problem with virtualenv in mkp4a.init
2020-02-27 09:56:51 +01:00
Shlomi Fish
96a91f6148 SHOULD_PUT_bye_for_now_FIRST = False
To avoid complaints about non random music.
2020-02-23 12:30:37 +02:00
Juhani Numminen
984ab3570a Import ttk from standard library, drop local copy 2020-02-11 23:38:28 +02:00
Juhani Numminen
97c957d055 Fix whitespace in pyramid.py 2020-02-11 22:10:00 +02:00
lufebe16
81fab2028a Corrections on game 'pyramid'
- For TypeError reported with #147. (clickhandler failed to return a value)
- For index out of range (in pyramid.y)
2020-02-10 18:01:20 +01:00
Juhani Numminen
80d99e508d Fix 'TclError: unknown option' for tk
Partly reverts commit b9a46ecf35
2020-02-09 22:19:47 +02:00
Juhani Numminen
032b645e0f Do not catch exceptions too broadly in mainloop
StopIteration seems to be the expected way to stop, at least
for the tk and tile interfaces.
2020-02-09 22:07:16 +02:00
Juhani Numminen
00f6f70e93 Fix menu colors on macOS with dark menu bar
Widget colors and all scrollbars look just fine without these lines
despite the comments.
2020-02-09 17:36:26 +02:00
Shlomi Fish
57b9c9d41e fix a crash on "open game" 2020-02-09 11:44:52 +02:00
Shlomi Fish
2258274c77 Refactoring / code cleanup.
Use a frozenset()-like list.

See:

* https://en.wikipedia.org/wiki/Code_refactoring

* https://www.refactoring.com/

* https://www.joelonsoftware.com/2002/01/23/rub-a-dub-dub/

Some small optimisations may have slipped in as well.
2020-02-07 11:44:24 +02:00
Shlomi Fish
0306d648fa fix load/save 2020-02-07 11:31:34 +02:00
Shlomi Fish
c2ec2d5195 Add 13 column Bisley - thanks to qunka.
See:

* https://github.com/shlomif/PySolFC/issues/148

* https://gist.github.com/qunka/3adac1878b481eb419ff6f3e1726add5

Thanks to https://github.com/qunka .
2020-01-07 11:38:37 +02:00
Shlomi Fish
b3f79c9df8 Extract a function or class to step away from God Object.
See:

* https://en.wikipedia.org/wiki/God_object

* https://www.c-sharpcorner.com/article/god-object-a-code-smell/ .

This is Refactoring / code cleanup.

See:

* https://refactoring.com/catalog/extractMethod.html

* https://en.wikipedia.org/wiki/Code_refactoring

* https://www.refactoring.com/

* https://www.joelonsoftware.com/2002/01/23/rub-a-dub-dub/

Some small optimisations may have slipped in as well.
2019-12-30 20:38:25 +02:00
Shlomi Fish
fab74e9a4b Extract a function or class to step away from God Object.
See:

* https://en.wikipedia.org/wiki/God_object

* https://www.c-sharpcorner.com/article/god-object-a-code-smell/ .

This is Refactoring / code cleanup.

See:

* https://refactoring.com/catalog/extractMethod.html

* https://en.wikipedia.org/wiki/Code_refactoring

* https://www.refactoring.com/

* https://www.joelonsoftware.com/2002/01/23/rub-a-dub-dub/

Some small optimisations may have slipped in as well.
2019-12-29 11:37:13 +02:00
Shlomi Fish
0f662fdb12 Extract a function or class to step away from God Object.
See:

* https://en.wikipedia.org/wiki/God_object

* https://www.c-sharpcorner.com/article/god-object-a-code-smell/ .

This is Refactoring / code cleanup.

See:

* https://refactoring.com/catalog/extractMethod.html

* https://en.wikipedia.org/wiki/Code_refactoring

* https://www.refactoring.com/

* https://www.joelonsoftware.com/2002/01/23/rub-a-dub-dub/

Some small optimisations may have slipped in as well.
2019-12-29 11:08:56 +02:00
Shlomi Fish
d7c87ca066 move functionality to pysol-cards PyPI module 2019-12-10 12:14:31 +02:00
Shlomi Fish
0961401105 fix tests 2019-11-13 08:39:59 +02:00
lufebe16
70fedf618a Added android permission request dialog 2019-10-14 19:58:22 +02:00
lufebe16
64cd1b73f2 Double tap added to cardselection (kivy toolkit)
- fixes issue #117
2019-10-02 11:35:56 +02:00
lufebe16
92f2d5f602 fixed2: allow game restore to accept older storage format. 2019-09-27 11:24:03 +02:00
lb@lb7520
97267e9a77 fixed: restore game 2019-09-26 12:21:58 +02:00
lb@lb7520
263858838f language selection
- option 'language' added to option section 'general'
- language selection code in kivy menubar
- mygettext refactored
- translations (german) updated
2019-09-25 19:46:17 +02:00
lb@lb7520
4a297ee434 german translations (revised) 2019-09-24 16:48:41 +02:00
lb@lb7520
6cc0ff767c german translations (mainly kivy/android related)
- updated kivy/android files
- executed 'make pot' to update message-ids
- german translations added
2019-09-23 19:55:50 +02:00
Juhani Numminen
65b86f2d1d Improve internationalization
- More strings marked for translation
- Used format strings instead of concatinating fragments
- Removed space before '?' or '!' from sentences in English

Following the GNU gettext guidelines at
https://www.gnu.org/software/gettext/manual/gettext.html#Preparing-Strings
2019-08-31 13:22:21 +03:00
Shlomi Fish
34609fc9d2 Extract a common class/struct.
This is Refactoring / code cleanup.

See:

* https://en.wikipedia.org/wiki/God_object

* https://en.wikipedia.org/wiki/Extract_class

* https://en.wikipedia.org/wiki/Code_refactoring

* https://www.refactoring.com/

* https://www.joelonsoftware.com/2002/01/23/rub-a-dub-dub/

Some small optimisations may have slipped in as well.
2019-08-29 16:55:47 +03:00
Shlomi Fish
a472160ca7 Extract a common class/struct.
This is Refactoring / code cleanup.

See:

* https://en.wikipedia.org/wiki/God_object

* https://en.wikipedia.org/wiki/Extract_class

* https://en.wikipedia.org/wiki/Code_refactoring

* https://www.refactoring.com/

* https://www.joelonsoftware.com/2002/01/23/rub-a-dub-dub/

Some small optimisations may have slipped in as well.
2019-08-27 21:32:20 +03:00
Juhani Numminen
a5d584371e Refactor and comment locale_dir selection 2019-08-20 16:23:05 +03:00
Juhani Numminen
93c9535216 Detect LANG for gettext on android 2019-08-20 11:54:49 +03:00
Shlomi Fish
7bbacfb97e Extract a method or a function.
This is Refactoring / code cleanup.

See:

* https://refactoring.com/catalog/extractMethod.html

* https://en.wikipedia.org/wiki/Code_refactoring

* https://www.refactoring.com/

* https://www.joelonsoftware.com/2002/01/23/rub-a-dub-dub/

Some small optimisations may have slipped in as well.
2019-08-14 20:49:03 +03:00
Shlomi Fish
0ffcc12afc Extract a common class/struct.
This is Refactoring / code cleanup.

See:

* https://en.wikipedia.org/wiki/God_object

* https://en.wikipedia.org/wiki/Extract_class

* https://en.wikipedia.org/wiki/Code_refactoring

* https://www.refactoring.com/

* https://www.joelonsoftware.com/2002/01/23/rub-a-dub-dub/

Some small optimisations may have slipped in as well.
2019-08-14 19:42:24 +03:00
Shlomi Fish
9b0b862406 Extract a common class/struct.
This is Refactoring / code cleanup.

See:

* https://en.wikipedia.org/wiki/God_object

* https://en.wikipedia.org/wiki/Extract_class

* https://en.wikipedia.org/wiki/Code_refactoring

* https://www.refactoring.com/

* https://www.joelonsoftware.com/2002/01/23/rub-a-dub-dub/

Some small optimisations may have slipped in as well.
2019-08-14 18:25:34 +03:00
Shlomi Fish
23843dc2a8 Extract a common class/struct.
This is Refactoring / code cleanup.

See:

* https://en.wikipedia.org/wiki/God_object

* https://en.wikipedia.org/wiki/Extract_class

* https://en.wikipedia.org/wiki/Code_refactoring

* https://www.refactoring.com/

* https://www.joelonsoftware.com/2002/01/23/rub-a-dub-dub/

Some small optimisations may have slipped in as well.
2019-08-14 17:59:27 +03:00
lb@lb520
5b75c1b413 Further corrections to python3 / android. Card images format has been changed to png. And a bugfix. 2019-08-12 09:50:38 +02:00
Shlomi Fish
15365f6267 moved functionality to pysol-cards.py 2019-08-08 18:44:49 +03:00
Shlomi Fish
c71c2fa07a Fix the 'picturegallery' game.
See https://github.com/shlomif/PySolFC/issues/140 . Thanks to
@scottfurry for testing.
2019-08-07 12:28:29 +03:00
Juhani Numminen
836eb54008 Add an error message to pysol_cards version check 2019-08-06 20:07:30 +03:00
Shlomi Fish
fd5bf10ddd moved functionality to pysol-cards.py 2019-08-04 18:47:19 +03:00
Shlomi Fish
0082962a93 Extract a common class/struct.
This is Refactoring / code cleanup.

See:

* https://en.wikipedia.org/wiki/God_object

* https://en.wikipedia.org/wiki/Extract_class

* https://en.wikipedia.org/wiki/Code_refactoring

* https://www.refactoring.com/

* https://www.joelonsoftware.com/2002/01/23/rub-a-dub-dub/

Some small optimisations may have slipped in as well.
2019-07-31 16:10:28 +03:00
Shlomi Fish
4d61d73f3a consolidate diffs 2019-07-30 12:37:22 +03:00
Shlomi Fish
6b228291cc update to latest pypi ver 2019-07-30 12:36:31 +03:00
Shlomi Fish
bc93657311 fix flake8 tests 2019-07-28 10:19:56 +03:00
Frédéric Brière
0abb801203 Define canMoveCards() for Hanafuda sequence stacks
Any stack of Hanafuda cards is always deemed movable, even if it is out
of sequence.  The effect can easily be seen a game such as Firecracker,
where:

 - Any stack can be dragged as a whole (but not released)
 - "Highlight piles" will highlight everything
 - Asking for a hint will ignore most valid moves

This is due to Hanafuda_SequenceStack lacking a canMoveCards() method.
2019-07-28 10:15:38 +03:00
Juhani Numminen
26631a7a22 Remove checks for individual cardsets' COPYRIGHT files
It is not strictly necessary to check the presence of the COPYRIGHT file
since pysollib/{tile,tk}/selectcardset.py will work even if it's missing.

In the Debian package, individual COPYRIGHT files are missing as all license
information should be in one file anyway, /usr/share/doc/pysolfc/copyright.

Thanks to Bernhard Reiter who originally wrote this patch:
https://salsa.debian.org/games-team/pysolfc/blob/87493fb/debian/patches/remove_checks_for_copyright_files
2019-07-28 10:05:05 +03:00
Juhani Numminen
1137dbb39b Improve Filesystem Hierarchy Standard compliance
These are actually for binaries, not data:
/usr/games       "Games and educational binaries"
/usr/local/games "Local game binaries"

The directories for the data:
/usr/share/games "Static data files for /usr/games"

"The requirements for the contents of [/usr/local/share] are the same as for
/usr/share."

Quoting https://refspecs.linuxfoundation.org/FHS_3.0/fhs-3.0.html
2019-07-28 10:05:05 +03:00
Shlomi Fish
70e1159947 consolidate diffs 2019-07-28 08:35:40 +03:00
Shlomi Fish
3c93a19508 Extract a common class/struct.
This is Refactoring / code cleanup.

See:

* https://en.wikipedia.org/wiki/God_object

* https://en.wikipedia.org/wiki/Extract_class

* https://en.wikipedia.org/wiki/Code_refactoring

* https://www.refactoring.com/

* https://www.joelonsoftware.com/2002/01/23/rub-a-dub-dub/

Some small optimisations may have slipped in as well.
2019-07-26 16:21:07 +03:00
Shlomi Fish
602f9ebc93 add missing attribute.
See https://github.com/shlomif/PySolFC/issues/129 .
2019-07-26 00:04:07 +03:00
Shlomi Fish
fb4f801ecc minimal ver of pysol_cards.
See https://github.com/shlomif/PySolFC/issues/128 .
2019-07-25 20:04:36 +03:00