-
Notifications
You must be signed in to change notification settings - Fork 3
Release 2.0 code changes #44
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- Supporting linking files - Support backing up workbox files, with ability to scroll forward and backward thru previous versions. Only workboxes / prefs with changes are saved - Colorize tabs indicating state (with toolTips) - Support auto-sync between multiple instances of PrEditor in same core - Support updating prefs args / values based on json file - Enforce unique tab names
- Uniform font / gui font keyboard modifiers - Remove QRegExp (deprecated, QRegularExpression not supported byQt.py) - Identifier classes now subclass py3 enums - update attr check name - Add copy filename context menu item - Better linked file comparisons by with `pathlib.Path` instances (ie remove `as_posix()` - Cleanup doc strings
- Don't set a workboxes tab_widget, always get it dynamically - Handle Reload messageboxes better
Better GRP & LYT names
Running in Houdini, the tab bar draws poorly, so remove overriding paintEvent, and instead use setTabTextColor and setTabTextToolTip. This means updating colors must be triggered, it doesn't come for free as in paintEvent.
- Simplify Options and Preferences layouts
- Add Prompt on Linked File Change option (you will get visual clues
even if this is turned off)
- Better handling of deleted / renamed linked files
- Handful of other small fixes
Add new methods: - connectSignals - createActions - setIcons - startFileSystemMonitor
Code highlighting is the slowest aspect of outputting text to the console. If long output is expected, considering disabling code highlighting.
Ask the user if they want to reset prefs if unable to parse preditor_pref.json.
This helps when developing for the stream or console classes if you cause an exception you might get no traceback printed to debug otherwise.
Also ensure that it writes unix newlines on windows
Restore StreamHandlerHelper removed in previous commit by moving it into the more appropriate location of stream.install_to_std.
- This allows them to write their messages even if they wouldn't normally. - Also remove legacy unused outputPipe. Instead add a callback to preditor.active.
This prevents all instances of the class sharing the same variable if modified without using the setter.
- Consolidate truncate code under preditor.utils.Truncate. - Move result printing into the Console class inside executeString.
Instead of stdout/err redirection. This can be configured using QtDesigner.
This improves the QtDesigner plugin behavior
This logs the inputs and return of the decorated function
This prevents cases where the hand cursor override gets stuck on if the mouse is quickly moved to another widget. It also seems to be processed faster.
1. Assume its encoded as utf-8 unless that causes an encoding error 2. Switch from chardet to charset-normalizer for encoding detection if otherwise detected Add a testing framework to verify that character encoding is resolved correctly.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This is a major refactoring of the preference files and workbox tabs. It also adds the new OutputConsole widget with a refactoring of the Console. These changes are drastic enough to warrant a major version up.
This Pull request merges all changes from the main2.0 branch into the main branch.
What's Changed
Warning: Preference saving has been re-worked. It will automatically migrate
to the new setup so you won't lose your current workbox tab contents. However
if you want to switch back to the 1.X release see "Reverting to v1.X prefs" below.
preditor.gui.output_console.OutputConsole, a widget for showing select python output.preditor.utils.Json.preditor.utils.call_stackproviding decorators that log the input and return of functions indenting for recursive calls.sys.__stderr__(ie. the console) for debugging.Reverting to v1.X prefs
In the rare case that you must revert to older Preditor (v1.X), you will only
see the workboxes you had when you updated to PrEditor v2.0. When you switch
back to v2.0 again, you still may only see those same workboxes. This can be
fixed with these steps, which in summary is to replace
preditor_pref.jsonwith one of the backups of that file.
Prefs files on disksection, click Browse. An Explorer window opens.prefs_bakfolderpreditor_pref.jsonpreditor_pref<timestamp>.jsonfile you copied, so it ispreditor_pref.jsonSource Pull Requests
Checklist
Types of Changes