-
Notifications
You must be signed in to change notification settings - Fork 4
Canvas GUI
The Seco user interface has the conventional menu, but the way it allows you to organize your work is a bit experimental. The main canvas is conceptually an infinite, zoomable 2D space. You can move through that space in any direction and you can zoom in and out at pretty much arbitrary depth. The space contains components such as notebooks, containers or any Swing component that your code has created and that you've dragged onto the space. You can zoom in and out in the top canvas, or any container, by right-clicking the mouse and dragging left or right. Speaking of containers...
Containers are nested spaces where you can place the same types of things that you can place in the top view, namely notebooks, other containers, and everything else. They are useful for creating working areas, analogous to your top-level working area, but that you can minimize away as a whole. You can also zoom in/out the inside of a container, just like the top view. To create a new container, select the Window->Add->Container menu. The same menu also lets you create a Tabbed Pane. The panes in a tabbed pane are, you guessed it, notebooks, containers, any kind of cell pretty much.
Anything on the canvas can have a visible box around it with a title bar. As in any windowing system, the title bar has a maximize and a minimize button (identified by + and the - signs). In addition, there is a 3d icon, the Move Button, a square at 45 degrees with a circle inside, that can be used to grab the thing and drag it in and out of containers. To switch the title bar on or off or to change the title as well as other such operations on a cell on the canvas, you can use the context menu:
To access the context menu of an object on the canvas, right-click on it while holding the Alt key down. The Alt key is actually very important. When you left-click on something, like a notebook or a container, you get to see a resizable border. Also, that's the way to bring a notebook into focus. You may be surprised that just clicking inside a notebook doesn't bring it on top of the z-order like windowing systems usually do. You need to be holding Alt for that. That's how it is in Seco. To move an object within the same container, left-click on it while holding the Alt key down, then drag it around. Note that this sort of moving is different from the one you do with the Move Button. Alt plus drag keeps you in the same container. The move button is to put something inside another container or get it out of there. Another important use of the Alt is the ability to work with the cell visual handle, the blue brackets on the right-hand side in a notebook, with they keyboard. For example, to delete cell, you have to select them by clicking on the blue brackets and then pressing the delete key. But instead of clicking you can also select by pressing the Alt+right arrow combination. This moves the focus from the notebook code area to the cell visual handles. After that you can move up and down the brackets with the arrow keys, do multiselects using Shift and Ctrl etc. When you are a done, go back to the code with Alt+left arrow.
So what makes the menu bar special in this sort of unconventional UI. Nothing really. In fact, the menu bar and tool bar are also components that can be dragged away from their current location. Conversely, other components can be pinned at a particular location so that get unaffected by zooming or movement. This pin/unpin functions are available from the context menu. At the time of this writing, this doesn't work very well though. Sorry. Come and help and fix it!