gzz-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Gzz-commits] fenfire ./README.MMDEMO org/fenfire/demo/mm.py ...


From: Asko Soukka
Subject: [Gzz-commits] fenfire ./README.MMDEMO org/fenfire/demo/mm.py ...
Date: Thu, 14 Aug 2003 04:42:57 -0400

CVSROOT:        /cvsroot/fenfire
Module name:    fenfire
Branch:         
Changes by:     Asko Soukka <address@hidden>    03/08/14 04:42:57

Modified files:
        .              : README.MMDEMO 
        org/fenfire/demo: mm.py 
        org/fenfire/view/lava: mindMapView2D.py 

Log message:
        some proposed changes

CVSWeb URLs:
http://savannah.gnu.org/cgi-bin/viewcvs/fenfire/fenfire/README.MMDEMO.diff?tr1=1.1&tr2=1.2&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/fenfire/fenfire/org/fenfire/demo/mm.py.diff?tr1=1.7&tr2=1.8&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/fenfire/fenfire/org/fenfire/view/lava/mindMapView2D.py.diff?tr1=1.9&tr2=1.10&r1=text&r2=text

Patches:
Index: fenfire/README.MMDEMO
diff -u fenfire/README.MMDEMO:1.1 fenfire/README.MMDEMO:1.2
--- fenfire/README.MMDEMO:1.1   Thu Aug 14 04:00:17 2003
+++ fenfire/README.MMDEMO       Thu Aug 14 04:42:56 2003
@@ -10,12 +10,22 @@
 This demo is meant to be a simple note taking tool built in the spirit
 of mindmap technique.
 
+------------------
+Used abbreviations
+------------------
+
+RMB
+       RightMouseButton
+
+LMB
+       LeftMouseButton
+
 -----
 Mouse
 -----
 
 RMB click
-       Changes the state, which affects the functionality of LMB.
+       Changes the state, which determines what the LMB click does.
 
          - selecting state; blue background; arrow cursor
           - linking state; green background; pointing hand cursor
@@ -33,10 +43,10 @@
        Unlinking state
                Unlinks the center node from the clicked node.
 
-LMB move
+LMB drag
        Moves the linked structure on the screen.
 
-RMB move up or down
+RMB drag up or down
        Zooms the linked structure. When a new center node is selected,
        the zooming will return to default.
 
@@ -44,15 +54,35 @@
 Keyboard
 --------
 
-Tab
-       Losts the accursed node.
+Escape
+       Removes the focus from the current accursed node and sets no
+        new accursed node.
+
+Typing
+       If there is no accursed node, typing would create a new node
+        into the floating buffer.
+
+Ctrl-S
+       Save the structure.
+
+Ctrl-R
+       Reload the demo.
+
+Ctrl-Q
+       Save the structure and quit.
+
+-------------------------------------
+Editing the text in the accursed node
+-------------------------------------
 
 Typing
-       Enters text into the accursed node. If there is no accursed
-        node, typing would create a new node into the floating buffer.
+       Enters text.
+
+Backspace
+       Removes a character before text cursor.
 
 Arrows
-       Moves text cursor within the accursed node.
+       Moves text cursor.
 
 Home or Ctrl-A
        Moves text cursor into the beginning of the line. 
@@ -65,13 +95,3 @@
 
 Ctrl-End
        Moves text cursor to the end of the text.
-
-Ctrl-S
-       Save the structure.
-
-Ctrl-R
-       Reload the demo.
-
-Ctrl-Q
-       Save the structure and quit.
-
Index: fenfire/org/fenfire/demo/mm.py
diff -u fenfire/org/fenfire/demo/mm.py:1.7 fenfire/org/fenfire/demo/mm.py:1.8
--- fenfire/org/fenfire/demo/mm.py:1.7  Thu Aug 14 03:36:37 2003
+++ fenfire/org/fenfire/demo/mm.py      Thu Aug 14 04:42:57 2003
@@ -125,7 +125,7 @@
         nodeview.getXY(fen.graph, context.getAccursed(), context.offset, xy)
         cs = vs.orthoCS(cs, "CURSOR", 0, xy[0]*self.scale, xy[1]*self.scale,
                         0, -textstyle.getHeight(self.scale))
-        vs.put(vob.vobs.LineVob(0,0,0,1, java.awt.Color.white), cs)
+        vs.put(vob.vobs.LineVob(0,0,0,1, java.awt.Color.black), cs)
 
     def insertText(self, text):
         if self._accursed == None:
@@ -303,7 +303,7 @@
         
     def key(self, key):
         if (dbg): p("key: ", key)
-        if key == 'Tab':
+        if key == 'Escape':
             context.setAccursed(None)
         elif key == 'Backspace':
             if context.getAccursed() != None:
Index: fenfire/org/fenfire/view/lava/mindMapView2D.py
diff -u fenfire/org/fenfire/view/lava/mindMapView2D.py:1.9 
fenfire/org/fenfire/view/lava/mindMapView2D.py:1.10
--- fenfire/org/fenfire/view/lava/mindMapView2D.py:1.9  Wed Aug 13 18:58:29 2003
+++ fenfire/org/fenfire/view/lava/mindMapView2D.py      Thu Aug 14 04:42:57 2003
@@ -19,8 +19,10 @@
 
 dbg = 0
 
-paper = vob.gl.SpecialPapers.selectionPaper(None);
+paper = vob.gl.SpecialPapers.selectionPaper(None)
+paper_accursed = vob.gl.SpecialPapers.selectionPaper(java.awt.Color(.9, .9, 
.9));
 whiteground = vob.gl.GLRen.createFixedPaperQuad(paper, 0, 0, 1, 1, 0, 10, 10, 
10);
+whiteground_accursed = vob.gl.GLRen.createFixedPaperQuad(paper_accursed, 0, 0, 
1, 1, 0, 10, 10, 10);
 
 class MindMapMainNode2D(ff.view.buoy.MainNode2D):
     def __init__(self, plane, view2d, focus, controller):
@@ -70,7 +72,9 @@
         p = self.viewfunc.f(self.fen.graph, node)
 
         cs_background = vs.orthoCS(cs,'WHITE_GROUND',0, 0, 0, p.getWidth(), 
p.getHeight())
-        vs.put(whiteground, cs_background)
+        if self.context and self.context.getAccursed() == node:
+            vs.put(whiteground_accursed, cs_background)
+        else: vs.put(whiteground, cs_background)
         
         cs = vs.orthoBoxCS(cs,node,0, 0, 0, 1,1, p.getWidth(), p.getHeight())
         p.place(vs, cs)
@@ -132,9 +136,6 @@
         self.tblsize = 20
         self.mode = 0
 
-        paper = vob.gl.SpecialPapers.selectionPaper(None);
-        self.whiteground = vob.gl.GLRen.createFixedPaperQuad(paper, 0, 0, 1, 
1, 0, 10, 10, 10);
-
     def getSize(self, node, wh):
         s = -1 # s = 240
         wh[0], wh[1] = s, s
@@ -298,7 +299,9 @@
         y = - p.getHeight()/2.0
 
         cs_background = vs.orthoCS(cs,'background',0, x,y, p.getWidth(), 
p.getHeight())
-        vs.put(whiteground, cs_background)
+        if self.context and self.context.getAccursed() == node:
+            vs.put(whiteground_accursed, cs_background)
+        else: vs.put(whiteground, cs_background)
 
         cs = vs.orthoBoxCS(cs, node,0, x,y, 1,1, p.getWidth(), p.getHeight())
         p.place(vs, cs)




reply via email to

[Prev in Thread] Current Thread [Next in Thread]