-
Notifications
You must be signed in to change notification settings - Fork 115
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
Dockable dialogs #420
base: master
Are you sure you want to change the base?
Dockable dialogs #420
Conversation
2xsaiko
commented
Jul 5, 2021
@@ -114,6 +113,16 @@ | |||
private final JTabbedPane openFiles; | |||
private final HashBiMap<ClassEntry, EditorPanel> editors = HashBiMap.create(); | |||
|
|||
private final WorkspaceRPanelContainer workspace = new WorkspaceRPanelContainer(); | |||
|
|||
private final RPanel structureRPanel; |
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.
Can this just be named structurePanel
?
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.
There's also the actual structure panel in a field called structurePanel
, so probably not.
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.
yup, I just picked the next best name I could think of, one of these (or both) will be renamed because all the other RPanels are just named *Panel
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.
there, now it's just structurePanel
;)
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.
Looks so good, glad you finally PRed it!
A few first-look things I noticed:
- Language does not change on click on RPanels unlike the rest of the UI
- Width of RPanels cannot be adjusted: it's the width of the text inside. This leads to very wide panels when the editor is not empty, and very thin otherwise
- Drag and drop doesn't work for me (yet I assume?)
- Details but the little java icons on every panel is a bit too much imo. Could be changed with proper icons or removed (
JFrame.setIconImage
)
yep, RPanel.setTitle seems to be broken, I didn't 100% test it since I had to add it in during the rebase (the original version of this code was written before on-the-fly language change was a thing)
WorkspaceRPanelContainer which is supposed to handle this is very WIP, I just started actually implementing it today
Yep, will have to see how to do that, especially dropping windows back into the main frame, I don't think it's something that Swing has anything preexisting (or at least documented) for, like pretty much any of what I'm doing here (hell, just look at RotationLayerUI, the entire class is just to rotate the buttons and I had to go through obscure StackOverflow questions to manage to put something together that actually works) Worst comes to worst, I'll have a menu on the panel that allows you to move it around like in IntelliJ but I'd really rather not because that's abysmal. I basically want to replicate how these work in Qt because the Qt dockable dialogs are great.
Yup, the icon is going away, it's definitely unnecessary (edit: depends on the theme, it isn't there in the first place with Metal so I never noticed it originally) |
f0632eb
to
d4c7314
Compare
993948a
to
348dd04
Compare