Commit Graph

7184 Commits

Author SHA1 Message Date
Philipp Wolfer
419ff87fea PICARD-1807: Fix error handling when using python-libdiscid
discid.disc.DiscError only exists in python-discid, not in the compat version of python-libdiscid. The proper way in both libraries is to access discid.DiscError.
2020-05-13 19:12:16 +02:00
Philipp Wolfer
651bbad60d Merge pull request #1534 from phw/PICARD-1812-riff-info
PICARD-1812: Save RIFF INFO tags for WAVE
2020-05-13 19:11:08 +02:00
Philipp Wolfer
d79d142a04 Refactor picard.formats and picard.coverart.providers to avoid circular dependencies 2020-05-13 17:04:11 +02:00
Philipp Wolfer
8c219d16a5 Enable flake8 E402: Module level import not at top of file
This also removes some exceptions for isort which are not really necessary.
2020-05-13 17:04:11 +02:00
Philipp Wolfer
0d22a2ae61 Update picard.pot 2020-05-13 14:05:57 +02:00
Philipp Wolfer
bb7c45ddf8 PICARD-1812: Tests for loading / saving RIFF INFO tags 2020-05-13 13:50:05 +02:00
Philipp Wolfer
63c951fc18 PICARD-1812: Use Windows-1252 for RIFF INFO by default
This provides best compatbility for Windows. Users can choose to select UTF-8 for Unicode support (e.g. supported by foobar2000).
2020-05-13 11:08:07 +02:00
Philipp Wolfer
1542d4d7c0 PICARD-1812: Option to remove RIFF INFO from WAVE files 2020-05-13 11:08:07 +02:00
Philipp Wolfer
b8644aad3d PICARD-1812: Options for saving RIFF INFO to WAVE 2020-05-13 11:08:07 +02:00
Philipp Wolfer
49338dc0ac PICARD-1812: Support saving LIST INFO to WAVE files 2020-05-13 11:08:07 +02:00
Philipp Wolfer
0996495cee PICARD-1128: Allow tagging WAVE files with ID3
Requires support in mutagen
2020-05-13 11:06:37 +02:00
Philipp Wolfer
da822d5d09 Set version to 2.4.0dev1 2020-05-13 11:06:36 +02:00
Philipp Wolfer
2c5a484b91 PICARD-1805: Add a default tagger script when user enables scripting
Also show a placeholder text in the script editor to make it clear where the user can input code.
2020-05-13 11:06:36 +02:00
RaysDev
7801fdfb71 Add date match constants and reorganized comments 2020-05-13 11:06:36 +02:00
Philipp Wolfer
e336534dda Updated requirements*.txt for dateutils 2020-05-13 11:06:36 +02:00
Ray
76a4ff0a61 fix small data dependent bug 2020-05-13 11:06:36 +02:00
Ray
5ec96234c5 Moved extract_year_from_date to utils and updated requirements.txt 2020-05-13 11:06:36 +02:00
Ray
86298d7911 Changes for year extraction from date 2020-05-13 11:06:36 +02:00
Ray
0696a53fa7 New Logic for considering release date in the matching process 2020-05-13 11:06:31 +02:00
Laurent Monin
a308c39343 preprocessor -> postprocessor
Suggested by @phw
2020-05-13 11:05:11 +02:00
Laurent Monin
20d631868a htmldoc(): reduce code redundancy a bit calling markdowndoc()
Suggested by @phw
2020-05-13 11:05:11 +02:00
Laurent Monin
eeb98c4284 Remove useless bits 2020-05-13 11:05:11 +02:00
Philipp Wolfer
683a3cc394 Removed markdown from requirements-(build|dev).txt 2020-05-13 11:05:11 +02:00
Philipp Wolfer
cfe004a558 ScriptTextEdit: Removed unneeded focusInEvent 2020-05-13 11:05:11 +02:00
Philipp Wolfer
10accc9735 Moved ScriptTextEdit into separate module and reuse it in renaming 2020-05-13 11:05:11 +02:00
Philipp Wolfer
738499db9a Use QCompleter.activated instead of custom signal 2020-05-13 11:05:11 +02:00
Philipp Wolfer
758667fefa Do not trigger autocomplete on cursor keys to allow for easier navigation 2020-05-13 11:05:11 +02:00
Philipp Wolfer
e76de5fc6b Allow auto completion for variables in script editor 2020-05-13 11:05:11 +02:00
Philipp Wolfer
5409f71a0f Improve the script editor auto completion
- Allow completion on $
- Always replace the full match
- Avoid autocompletion triggering on whitespace between words
2020-05-13 11:05:11 +02:00
Bob Swift
edfb8be3ad Update $find documentation 2020-05-13 11:05:11 +02:00
Bob Swift
b2f7330850 Add platform-specific note to $datetime 2020-05-13 11:05:11 +02:00
Laurent Monin
03d8d69776 Renames (again) 2020-05-13 11:05:11 +02:00
Laurent Monin
dd00c084d5 More renames 2020-05-13 11:05:11 +02:00
Laurent Monin
6a8e57c532 Rename few files and classes 2020-05-13 11:05:11 +02:00
Laurent Monin
053500cce3 Tidy up, renames & cosmetics 2020-05-13 11:05:10 +02:00
Laurent Monin
90e7d329ac Clean up imports 2020-05-13 11:05:10 +02:00
Laurent Monin
78a5ef5446 Use a more generic label to the button as we may display more than func doc 2020-05-13 11:05:10 +02:00
Laurent Monin
2d29915551 Move external documentation link to the in-app script doc dialog 2020-05-13 11:05:10 +02:00
Laurent Monin
13ef6d9a9c Add simple completion to script editor, using list of known functions 2020-05-13 11:05:10 +02:00
Laurent Monin
1ea62c21a7 Introduce script_function_names() to get a sorted list of registered function names 2020-05-13 11:05:10 +02:00
Laurent Monin
7ec406f8bd Display module for script functions registered outside picard 2020-05-13 11:05:10 +02:00
Laurent Monin
803bc78795 Support incorrectly formatted documentation string
We were assuming there was one first line then description, but if someone
register a function with minimal documentation it can be:

```python
@script_function(documentation="minimal doc")
def myscriptfunc():
    do_something();
```

Without this change, an exception was raised (only one line).
Now it tries to use actual function name and displays as:

```
$myscriptfunc(...)

    minimal doc
```
2020-05-13 11:05:10 +02:00
Laurent Monin
4119fc0514 Pass FunctionRegistryItem object to preprocessor
No need to have proprocessor as a property
2020-05-13 11:05:10 +02:00
Laurent Monin
655e7faca1 Translate script function documentation bits 2020-05-13 11:05:10 +02:00
Laurent Monin
edc6bbf72b Tidy up 2020-05-13 11:05:10 +02:00
Laurent Monin
06c2618232 Improve script function documentation formatting, using dl/dt/dd html tags
Make color of the first line configurable (demo mode)
2020-05-13 11:05:10 +02:00
Laurent Monin
9d2c12fa25 Use ul/li 2020-05-13 11:05:10 +02:00
Laurent Monin
221b9bc9fa Add all scripting functions documentation
Remove redundant Python docstrings
2020-05-13 11:05:10 +02:00
Laurent Monin
d425011c21 Use QTextBrowser instead of QTextEdit
So we can have external links in the documentation
2020-05-13 11:05:10 +02:00
Laurent Monin
329f26acb6 Lint (again) 2020-05-13 11:05:10 +02:00