|
|
Home » Developing U++ » UppHub » Docking package (plus examples)
|
|
|
|
Re: Docking package (plus examples) [message #15060 is a reply to message #14955] |
Thu, 27 March 2008 20:25 |
cbpporter
Messages: 1406 Registered: September 2007
|
Ultimate Contributor |
|
|
Hi!
I finally got to the point where I can use your tabbing system. It was not that easy, because if you try to design the "perfect" interface without taking into consideration dockable windows, you can hardly insert this concept in the interface so that it feels natural.
But I found a way to improve my interface, but it seems that I have special needs . I wonder if you system could be adapted so that a layout is formed only by docked windows, without a main layout? First docked window takes full surface, second takes half and there is only one splitter. It would be nice if certain windows can be configured to tile vertically, and others horizontally. I believe this is some work and I'm not asking you to implement this for me. It is just an idea of what I would like to have, and I'm certain I can get it to work after some hacking by inserting a dummy header into the main layout, and an option to dynamically switch the context of it. But this is something for the future.
Something that is for now is a bug. I found that if you slowly drag a dock over a blueish highlighted surface you can leave a trail. To reproduce, open your test example, dock any window on the left for example. Take a second floating window, and drag it over the first one which is docked now. A blue highlight will appear. Move it around until the highlight covers the whole window (not just top or bottom). After the highlight appears, without releasing the mouse, move the window arround and you will see a trail.
|
|
|
|
|
Re: Docking package (plus examples) [message #15070 is a reply to message #15060] |
Fri, 28 March 2008 14:45 |
mrjt
Messages: 705 Registered: March 2007 Location: London
|
Contributor |
|
|
Something that is for now is a bug.
Thanks, I was trying to do it with a transparent Ctrl, which doesn't work very well in Upp . Fixed now.
But I found a way to improve my interface, but it seems that I have special needs Smile.
If I understand correctly this actually doesn't sound too difficult to do, but is quite different to how the docking works at the moment. What you actually need is a single ctrl like a tree of splitters:
Internal structure:
H- horizontal splitter node
V- vertical splitter node
cN- ctrls (leaves)
Root (horizontally split)
/ \
H V
/ \ / \
V c3 c4 c5
/ \
c1 c2
Appearance:
-------------
|c1| | |
| | | c4 |
|--|c3|-----|
|c2| | c5 |
| | | |
-------------
and then add the abitility to drag-drop the ctrls around. It's an interesting concept, if you can make it work right. I've already got a SplitterTree ctrl so I might have a quick play with it. You can also just implement this by adding splitters to splitters to form the tree, but this gets unwieldy quite quickly.
James
[Updated on: Fri, 28 March 2008 17:09] Report message to a moderator
|
|
|
|
|
Re: Docking package (plus examples) [message #15080 is a reply to message #15077] |
Fri, 28 March 2008 20:55 |
cbpporter
Messages: 1406 Registered: September 2007
|
Ultimate Contributor |
|
|
Quote: | Well, that was easy. Quite a bit of deleting, about 20 lines of code and we have a new interface.
|
Wow! That even sounds easy! I was aware of an approach with multiple splitters, but before I would have produced something with the fraction of the functionality of you framework it would have certainly taken me quite some time.
And I really like it. It was exactly what I was hopping for. You see, I have o TotalCmd like interface, with the left side different from the right side. Each side has for choseable layouts. With the previous version of the docking package I would have had to select one of them and make them the main layout and second with a dock and the rest of them as pre-hidden ones. This is all OK, but the design goals was to have both windows on the screen at the same time and they both have the same importance.
But with this new layout scheme, I can definitely get the ultimate (no pun intended) end user configuration possibility. I certainly think this has nice potential, and could possibly be used to emulate MDI/split screen document structure too.
And now for the bugs:
1. If you undock all windows, none can be docked again.
2. The ability to choose from the interface a position for docking is gone. As far as I can tell, this was dropped because position are no longer that straightforward. But still, a nice left and right at left could be achievable.
3. If I put a window to autohide, then I wait for it to appear and click on it's option button, a menu appears, but the window will automatically hide again. It should stay until the menu is closed.
4. Windows set to autohide can not be dragged away anymore.
5. Let an autohide open and quickly resize the window. You will see the pop-up borderless window stay in place.
Items 3 (only noticed for top position autohide docks) and 5 are also in the old code.
Anyway, thank you for giving my idea a shot .
|
|
|
Re: Docking package (plus examples) [message #15100 is a reply to message #15080] |
Mon, 31 March 2008 12:32 |
mrjt
Messages: 705 Registered: March 2007 Location: London
|
Contributor |
|
|
cbpporter wrote on Fri, 28 March 2008 19:55 | But with this new layout scheme, I can definitely get the ultimate (no pun intended) end user configuration possibility. I certainly think this has nice potential, and could possibly be used to emulate MDI/split screen document structure too.
And now for the bugs:
1. If you undock all windows, none can be docked again.
2. The ability to choose from the interface a position for docking is gone. As far as I can tell, this was dropped because position are no longer that straightforward. But still, a nice left and right at left could be achievable.
3. If I put a window to autohide, then I wait for it to appear and click on it's option button, a menu appears, but the window will automatically hide again. It should stay until the menu is closed.
4. Windows set to autohide can not be dragged away anymore.
5. Let an autohide open and quickly resize the window. You will see the pop-up borderless window stay in place.
Items 3 (only noticed for top position autohide docks) and 5 are also in the old code.
Anyway, thank you for giving my idea a shot .
|
No problem. As I said it wasn't difficult to do and I agree that it's a nice interface for certain apps.
Item 4 on your list I haven't been able to reproduce. I've tested it on XP, Gnome and KDE and that portion of the code is identical to the original package (and hasn't changed for some time). Can you give more details? All the other items are fixable, though 3 is going to be difficult. The problem is that I'm not sure what to do with the code now.
If you'd like to use it I can fix 1, 2 & 4 and add serialization by the end of the week, which makes it useable in a real-world app. But unless there is interest from other parties I can't really justify maintaining it and adding Animation, which is a real pain. Unfortunately although 90% of the code is the same as the original docking package it's different enough that I can't see how to merge the two.
So let me know if you'd like me to make it useable and I'll have to think about what to do about maintaining it.
James
[Updated on: Mon, 31 March 2008 12:36] Report message to a moderator
|
|
|
|
|
Re: Docking / DockTest packages [message #15209 is a reply to message #14888] |
Wed, 09 April 2008 16:34 |
mrjt
Messages: 705 Registered: March 2007 Location: London
|
Contributor |
|
|
I've updated the Docking package in the SVN.
SVN Revision 211 Changes:
- Major improvement to the Smart-Resize algorithm. Works very well now.
- Additional window animation (floating windows now 'slide' into place when docked).
- Improved group tree in config window
- Some internal refactoring and various little fixes. No major bugs (none found ).
James
[Updated on: Thu, 10 April 2008 16:10] Report message to a moderator
|
|
|
Re: Docking package (plus examples) [message #15275 is a reply to message #15102] |
Tue, 15 April 2008 00:21 |
cbpporter
Messages: 1406 Registered: September 2007
|
Ultimate Contributor |
|
|
mrjt wrote on Mon, 31 March 2008 17:47 | Good luck That sounds like a reasonable plan, let me know if you need any help. The code can be slighly unruly in places but there is a structure and design to it (mainly an attempt to create a small public interface and maintain loose-coupling between the internal classes). The DockCont class is the worst bit but that handles the tabbing/nesting and you shouldn't have to worry about it.
|
Wow, that took me a lot longer than expected! I have now a basic grasp of the inner workings of your code. This is good, but right now I don't know what to do with it. The next update of my app got published with the same TC like interface, and so far there were no complains regarding it. So I don't know if maintaining a fork of your docking system would be a wise decision, especially since the next update is planned for August. But I would like to investigate a way to make any control pop-upable (is that a word ) with minimal impact on core packages.
But I really love your tree code. I wonder what the impact of a college course (if there are still C++ courses, with all the Java ones)which teaches such tree data would have. Unfortunately, here in my local city at it's relatively high regarded Computer Science course, tree structures (and other data structures) as well are thought with nasty plain C style. This is fine for an introductory level, but taking into account the shear number of hours dedicated to the subject, some higher level stuff would be welcome. And I'm sure that 75% of students would break their teeth on that code .
|
|
|
Re: Docking package (plus examples) [message #15279 is a reply to message #15275] |
Tue, 15 April 2008 10:56 |
mrjt
Messages: 705 Registered: March 2007 Location: London
|
Contributor |
|
|
cbpporter wrote on Mon, 14 April 2008 23:21 | So I don't know if maintaining a fork of your docking system would be a wise decision
|
Cool. I'd like to come back to this later though, perhaps after I've finished with the main package and can think of integrating them somehow. I think it's an interesting paradigm that I haven't seen anywhere else so it's a fun experiment.
Quote: | But I would like to investigate a way to make any control pop-upable (is that a word Smile ) with minimal impact on core packages.
|
I'm not quite sure what you mean (presumably not just calling Popup on a ctrl), but if you can give me a more detailed description I'm sure I can help. I consider myself a bit of an expert of that subject now
Quote: | But I really love your tree code. I wonder what the impact of a college course (if there are still C++ courses, with all the Java ones)which teaches such tree data would have. Unfortunately, here in my local city at it's relatively high regarded Computer Science course, tree structures (and other data structures) as well are thought with nasty plain C style. This is fine for an introductory level, but taking into account the shear number of hours dedicated to the subject, some higher level stuff would be welcome. And I'm sure that 75% of students would break their teeth on that code Twisted Evil.
|
No doubt I'm still not sure myself whether the Tree class was a stroke of brilliance or absolute madness. And I couldn't write code like that before encountering Upp and reading lots of Mirek's code, but I did at least get taught lots of C++ data structures on my CS course (and Computational Geometry).
Some/all of the traverses don't work correctly I'm afraid, I didn't notice until I tried to do serialization and I haven't got round to fixing them yet.
|
|
|
Re: Docking package (plus examples) [message #16041 is a reply to message #15279] |
Fri, 23 May 2008 18:21 |
mrjt
Messages: 705 Registered: March 2007 Location: London
|
Contributor |
|
|
Just a quick post so that it doesn't look like the package is dead really. I haven't been posting updates since there aren't really any new features, just incremental improvements.
X11 support has been improved (including performance).
TabBar theming has been much improved thanks to unodgs.
API documentation is now included.
Many bugs squashed.
[Updated on: Fri, 23 May 2008 18:38] Report message to a moderator
|
|
|
Re: Docking package (plus examples) [message #16042 is a reply to message #16041] |
Sat, 24 May 2008 01:05 |
Oblivion
Messages: 1112 Registered: August 2007
|
Senior Contributor |
|
|
Quote: |
Just a quick post so that it doesn't look like the package is dead really. I haven't been posting updates since there aren't really any new features, just incremental improvements.
X11 support has been improved (including performance).
TabBar theming has been much improved thanks to unodgs.
API documentation is now included.
Many bugs squashed.
|
Well, mrjt congratulations. It seems that you have won the "competition" (If there was one) I was away for a long while and I had to pause the development of my DockCtrl package, since I was very busy with my other projects and my ph.d. I'm sorry for that, but I'm glad to see that, at least it encouraged you to finalize your solution (or I hope so ) And one more thing, if you would like to use my packages control panel style, etc. and "DockCtrl" label for your docking package, please do it.
Well, for me, probably, I'll come up with something totally new (a new ctrl maybe) and/or some additons/ideas to your package (if you ask for any) this summer
And I would like to thank the U++ community for their support to the DockCtrl package.
Regards.
Github page: https://github.com/ismail-yilmaz
upp-components: https://github.com/ismail-yilmaz/upp-components
Bobcat the terminal emulator: https://github.com/ismail-yilmaz/Bobcat
[Updated on: Sat, 24 May 2008 01:12] Report message to a moderator
|
|
|
|
Goto Forum:
Current Time: Fri Sep 20 06:40:08 CEST 2024
Total time taken to generate the page: 0.04781 seconds
|
|
|