-
-
Notifications
You must be signed in to change notification settings - Fork 938
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
Port EditGCodeDialog from PrusaSlicer #3417
Port EditGCodeDialog from PrusaSlicer #3417
Conversation
from prusa3d/PrusaSlicer@32ff20d Co-authored-by: YuSanka <[email protected]>
Original Commit: prusa3d/PrusaSlicer@7db83d5 Co-authored-by: YuSanka <[email protected]>
Only current issue is that the grabber for the resizeable window is currently white (ongoing issue for Orca) Original Commit: prusa3d/PrusaSlicer@a8307bf Co-authored-by: YuSanka <[email protected]>
+ GUI_App : Fixed update of the dark mode, when DataViewCtrl doesn't have header -Orca: currently doesn't seem to display dataview labels properly. TBD if it continues to be an issue. Original Commit: prusa3d/PrusaSlicer@c577b7f Co-authored-by: YuSanka <[email protected]>
Original Commit: prusa3d/PrusaSlicer@59af551 Co-authored-by: YuSanka <[email protected]>
Included pre-generated files specific to Orca rather than PS provided files Original Commit: prusa3d/PrusaSlicer@55d5921 Co-authored-by: YuSanka <[email protected]>
Original Commit: prusa3d/PrusaSlicer@b2bd7f5 Co-authored-by: YuSanka <[email protected]>
Original Commit: prusa3d/PrusaSlicer@d652f15 Co-authored-by: YuSanka <[email protected]>
Orca: Added option to use CMake config option ORCA_CHECK_GCODE_PLACEHOLDERS to check custom gcode placeholders rather than using debug Original Commit: prusa3d/PrusaSlicer@b8bb7f2 Co-authored-by: YuSanka <[email protected]>
Original Commit: prusa3d/PrusaSlicer@83b8988 Co-authored-by: YuSanka <[email protected]>
Original Commit: prusa3d/PrusaSlicer@7efdbec Co-authored-by: Lukas Matena <[email protected]>
Original Commit: prusa3d/PrusaSlicer@361ef22 Co-authored-by: YuSanka <[email protected]>
Add new icons from PS and update to use Orca color scheme Original Commit: prusa3d/PrusaSlicer@37afe79 Co-authored-by: YuSanka <[email protected]>
Also organized and added missing options to `s_CustomGcodeSpecificPlaceholders`
Dialog now shows all issues within the same dialog If a custom gcode value is not specified within the config, a testing value is added. This ensures that (most) of the custom gcode is parsed, and thus checked against the definitions.
# Conflicts: # src/slic3r/GUI/OG_CustomCtrl.cpp # src/slic3r/GUI/OG_CustomCtrl.hpp
This should be reverted when wxWidgets 3.2.1 is re-implemented
make sure that the local copy of the config is being used when checking if there is custom gcode otherwise it would be possible it doesn't get run during testing
sorry about the couple of extra PRs created. I had merged some of the changes from the wx upgrade ahead of time and it cause issues because of the reversion. Some cherry picking magic later, new branch! |
@Ocraftyone and @SoftFever, I noticed your check builds were failing. I ran into the same issue here today and found that it's because the site hosting Boost (https://boostorg.jfrog.io/artifactory/main/release/1.78.0/source/boost_1_78_0.tar.gz) was returning "409 Conflict". Now it's prompting for the original registrant's email address to be added. TL;DR, I got a copy of Boost from here: https://sourceforge.net/projects/boost/files/boost/1.78.0/boost_1_78_0.tar.gz I put it in the OrcaSlicer\deps\DL_CACHE\Boost directory and after that, I could successfully compile. Just a PITA. lol |
@Ocraftyone Also I'm not sure where to find the related logfile. setup
|
Nice one this PR! There are so many gcode options that knowing them all is impossible! UI wise on an M1 Pro MacBook Pro Screen.Recording.2024-01-12.at.12.13.21.movWhen clicking an option the list is momentarily refreshed displaying that option as a label for all Gcode placeholders. Once the tree loads, the correct values are displayed. |
@igiannakas would mind trying PrusaSlicer and see if it does something similar? |
Yeap it does exactly the same... It's cosmetic so no real issue, but was the only thing I could see! Another thing to consider is possibly filtering the list by the options available to the current print model - for example ramming doesn't apply to BBL printers etc. Again, that is polishing type stuff. |
That would be nice, but it would be a pretty manual process of determining all of the options that don't apply to BBL printers. Unless there is somewhere that specifies the options that are disabled or there are only a handful of options that would need to be disabled, I am hesitant to do that. As for the dataview issue, do you have the same issue with the object list dataview? Maybe it has some logic to alleviate this. While building this, I saw that there were some options indicating that you can set an animation for expanding and collapsing items, but I did not mess with them. Maybe it has to be explicitly disabled for mac. |
Just got a chance to test on ubuntu and I am getting a seg fault. I am having trouble building it in my test environment with github codespaces, so I still haven't been able to debug it yet. |
@@ -373,22 +373,31 @@ void OG_CustomCtrl::OnMotion(wxMouseEvent& event) | |||
break; | |||
} | |||
|
|||
for (size_t opt_idx = 0; opt_idx < line.rects_undo_icon.size(); opt_idx++) | |||
size_t undo_icons_cnt = line.rects_undo_icon.size(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Curiously, what are these changes for?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I believe a lot of it is a refactor. Rather than having multiple loops, it is a single loop that handles all cases
@@ -41,7 +41,120 @@ wxString double_to_string(double const value, const int max_precision = 4); | |||
wxString get_thumbnail_string(const Vec2d& value); | |||
wxString get_thumbnails_string(const std::vector<Vec2d>& values); | |||
|
|||
class Field { | |||
class UndoValueUIManager |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just trying to understand here: if I'm not wrong, this micro refactoring is not directly related to the EditGCodeDialog, right?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
According to the commits from PS, it was a refactoring done in preparation for the dialog. It is still fully compatible. The EditUIManager IS directly related.
src/slic3r/GUI/OptionsGroup.hpp
Outdated
|
||
inline Line* get_line(const t_config_option_key& id) { | ||
for (Line& line : m_lines) | ||
if (line.has_only_option(id)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Shall we is_separator() too?
I can't recall the exact causes why I added that check. I remember there were crashes caused by separators
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ill look back into the commit it was added and get back to you
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The commit is from the implementation of internal bridge speed. I didn't get any crashes, but that doesn't mean much. I am kinda leaning towards just going back the the original BBL function...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
hehehe, that change was introduced by myself.
It was crashing when a separator line was added
@discip I fixed that linux crash. It was one of the STUPIDEST mistake I have ever made, but its fixed now! 🤦 |
@Ocraftyone People who don't make mistakes never learn anything and are most likely doing nothing. You're doing fine. 👍 |
Ain't that the truth! |
@Ocraftyone Indeed, it works now on Linux as well, but I think the color of the text is definitely too dim: Just that. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fantastic work!
Thank you very much
Sorry to bother, but unfortunately this issue persists.
setup
|
@discip I'll take a look when I get a chance. I had meant to before merging but I will try to get a patch together. |
@Ocraftyone |
Is the text really that dark on Linux? Is there a light mode or similar available? |
This is a screenshot. 😆 In the linux version there is no option to choose from. |
This is a port of the EditGCodeDialog from PrusaSlicer 2.7.x. There were a few changes made to make it a bit more functional. Also, it isn't quite fully complete, but it should be in a very usable state.
General Changes:
Differences from PrusaSlicer's Implementation:
ORCA_CHECK_GCODE_PLACEHOLDERS
to toggle the above report since our workflow rarely uses debug mode.print.config()
in Gcode.cpp were changed tom_config
to support the above testing values feature (only m_config is modified with the placeholders andprint.config()
would return an empty string)TODO: