diff options
Diffstat (limited to 'doc.go')
| -rw-r--r-- | doc.go | 69 |
1 files changed, 56 insertions, 13 deletions
@@ -1,14 +1,57 @@ -package widget +/* +# 2D geometry values + +There are lots of issues when supporting multiple toolkit plugin +geometries. The geometries vary widely especially between the +graphical displays and the serial console ones. [Graphical Widget](http://en.wikipedia.org/Graphical_Widget) + + + To simplyfy this, we stick to using the concepts: + + ------------------------------ ^ + | top | | + | | | + | left right | height + | | | + | bottom | | + ------------------------------ v + + <----------- width ----------> + +This way, width & height are always positive numbers. -// passes information between the gui package and the toolkit plugins -// -// This is the only thing that is passed between the toolkit plugin -// -// what names should be used? This is not part of [[Graphical Widget]] -// Event() seems like a good name. -// Event is used too much: web dev, cloud, etc -// I'm using "Action". Maybe it should really be -// "Interaction" as per wikipedia [[User interface]] -// -// TODO: convert this to a protobuf (?) -// +The qustion of (top,bottom) & (left,right) becomes problematic. + +In almost every toolkit, right > left. However, top & bottom +vary and a choice can not be made easily. Luckily, we maybe do +not have to make that decision here and can pass that determination +to the toolkits. So, we use excusively: + + geom(left, right, top, bottom) + size(width, height) + +# Orientation + +Horizontal means layout widgets like books on a bookshelf + + --------------------------------- + | W | W | W | W | W | W | W | W | + | i | i | i | i | i | i | i | i | + | d | d | d | d | d | d | d | d | + | g | g | g | g | g | g | g | g | + | e | e | e | e | e | e | e | e | + | t | t | t | t | t | t | t | t | + --------------------------------- + +Vertical means layout widgets like books in a stack + ---------- + | Widget | + ---------- + | Widget | + ---------- + | Widget | + ---------- + | Widget | + ---------- +*/ +package widget |
