Commit graph

23 commits

Author SHA1 Message Date
Romain Bignon
eaf6b15a08 dump of tiles: save full image too 2014-10-21 17:56:18 +02:00
smurail
ab15874754 fix not logical arguments order 2014-10-21 10:28:18 +02:00
Laurent Bachelier
e783f2c821 Remove tuple method parameters
They can be found through autopep8 (W690) or python-modernize.
Variables manually renamed.

This is because Python 3 does not support tuple unpacking:
http://legacy.python.org/dev/peps/pep-3113/
2014-10-10 23:41:44 +02:00
Laurent Bachelier
6161a0aacd pep8 fixes, modernizations
autopep8 -a -r -i --select E711,E712,W601,W602,W603,W604,W690,E304,E401,E502 .
Also includes some manual reindentations (many are left after the print()
changes).
Manually checked, some modernizations not commited here.
2014-10-10 23:41:43 +02:00
smurail
530bcc6bc4 add a grid based virtual keyboard 2014-08-21 16:25:30 +02:00
smurail
61badd3228 add a margin attribute 2014-08-21 16:25:27 +02:00
smurail
1b9c6e388f refactor: more flexible constructor 2014-08-21 16:21:55 +02:00
smurail
73025adf6d some little cleaning 2014-08-21 16:21:55 +02:00
Florent
74f15059e9 Fix Pillow import in core 2013-06-06 13:49:39 +02:00
Laurent Bachelier
7094931c92 Easy spacing fixes, trailing stuff
Remove useless trailing \
Remove trailing spaces
Add missing empty lines

autopep8 -ir -j2 --select=E301,E302,E502,W291,W293,W391 .

Diff quickly checked.
2013-03-16 00:54:55 +01:00
Florent
8c66ca83c8 Remove unused imports 2013-03-02 10:31:34 +01:00
Florent
9dc9157062 Prevent useless debug folders 2013-03-01 13:41:50 +01:00
Romain Bignon
535d6efc47 more explicit error messages during common import errors 2013-01-14 21:28:47 +01:00
Romain Bignon
123eb4f32b add a parameter "convert" 2013-01-10 13:20:34 +01:00
Romain Bignon
40bce697ac add an overridable method to check pixel colors 2013-01-03 18:04:22 +01:00
Laurent Bachelier
006e97a8be PEP8 style fixes and other small style fixes
I used autopep8 on some files and did carefully check the changes.
I ignored E501,E302,E231,E225,E222,E221,E241,E203 in my search, and at
least E501 on any autopep8 run.

Other style fixes not related to PEP8:
* Only use new-style classes. I don't think the usage of old-style
  classes was voluntary. Old-style classes are removed in Python 3.
* Convert an if/else to a one-liner in mediawiki, change docstring style
  change to a comment something that wasn't really appropriate for a
  docstring.
* Unneeded first if condition in meteofrance
2012-03-14 04:51:46 +01:00
Pierre Mazière
99a45daae8 MappedVirtKeyboard: fix default value for map_attr
Signed-off-by: Pierre Mazière <pierre.maziere@gmail.com>
2012-01-24 23:51:59 +01:00
Pierre Mazière
2310e8506f MappedVirtKeyboard: set <map> attribute to return
Rather than imposing onclick, the map attribute whose value is returned
when retrieving a code is now a constructor argument
For the sake of backward compatibility, default is set to onclick

Signed-off-by: Pierre Mazière <pierre.maziere@gmail.com>
2012-01-24 23:51:56 +01:00
Pierre Mazière
a5453326e0 Add MappedVirtKeyboard class
This is useful for virtual keyboard based on the usemap
attribute of an IMG tag

Signed-off-by: Pierre Mazière <pierre.maziere@gmail.com>
2011-11-04 10:11:32 +01:00
Pierre Mazière
2fdb2fe36a VirtKeyboard: add check_symbols method
This method allows one to verify, before any decoding attempt,
if all the symbols given as arguments can be found in the
virtual keyboard.

Signed-off-by: Pierre Mazière <pierre.maziere@gmail.com>
2011-11-04 10:10:23 +01:00
Pierre Mazière
d9b51c406d VirtKeyboard: symbol detection improvement
Signed-off-by: Pierre Mazière <pierre.maziere@gmail.com>
2011-11-04 10:09:47 +01:00
Pierre Mazière
b14079a31e VirtKeyboard: make color argument mandatory
Signed-off-by: Pierre Mazière <pierre.maziere@gmail.com>
2011-11-04 10:08:33 +01:00
Pierre Mazière
165d264ecb VirtKeyboard: move to weboob/tools/captcha/
Signed-off-by: Pierre Mazière <pierre.maziere@gmail.com>
2011-11-04 10:07:09 +01:00