Permalink
Browse files

Slight speedups to textboxes by using noLoop() and redraw()

  • Loading branch information...
revarbat committed Aug 24, 2010
1 parent ee824e5 commit 1b3a9a86fb3b3be9a80d3effd090730dff7371c7
Showing with 6 additions and 7 deletions.
  1. +1 −0 GUI.pde
  2. +4 −6 SuperSkein.pde
  3. +1 −1 config.txt
View
@@ -211,6 +211,7 @@ class GUIFloatBox{
if((KeyStroke==8)&(Text.length()>0))Text=Text.substring(0,Text.length()-1);
if((KeyStroke>31)&(KeyStroke<177))Text = Text + char(KeyStroke);
Valid=true;
+ redraw();
}
}
View
@@ -116,7 +116,7 @@ void setup(){
PrintHeadSpeed = MyConfig.PrintHeadSpeed;
LayerThickness = MyConfig.LayerThickness;
Sink = MyConfig.Sink;
-
+ noLoop();
}
//This executes on Exit
@@ -175,7 +175,6 @@ void draw()
STLLoadProgress.update(STLLoadFraction);
STLLoadButton.display();
STLLoadProgress.display();
-
}
@@ -194,7 +193,6 @@ void draw()
Line2D Intersection;
Slice = new ArrayList();
-
//Draw the grid
stroke(80);
strokeWeight(1);
@@ -251,15 +249,15 @@ void mousePressed()
if(RightButton.over(mouseX,mouseY))GUIPage++;
if(GUIPage==3)GUIPage=0;
if(GUIPage==-1)GUIPage=1;
+ redraw();
}
void keyTyped()
{
if(GUIPage==0)STLName.doKeystroke(key);
if(GUIPage==0)STLScale.doKeystroke(key);
- if(GUIPage==0)STLXRotate.doKeystroke(key);
-
-
+ if(GUIPage==0)STLXRotate.doKeystroke(key);
+ redraw();
}
View
@@ -1,4 +1,4 @@
-CONFIG_SCALE 10.0
+CONFIG_SCALE 1.12
CONFIG_XROTATE 0.0
CONFIG_STLFILE C:\git\SuperSkein\triess_printable03.stl
MACHINE_OPTEMP 220

0 comments on commit 1b3a9a8

Please sign in to comment.