MinimumSize=50,50;
Width = 150;
Height = 150;
+}
+Border {
+ Foreground = White;
}
\ No newline at end of file
this.KeyDown += KeyboardKeyDown1;
testFiles = new string [] { @"Interfaces/Divers/welcome.crow" };
- //testFiles = testFiles.Concat (Directory.GetFiles (@"Interfaces/Unsorted", "*.crow")).ToArray ();
+ testFiles = testFiles.Concat (Directory.GetFiles (@"Interfaces/Unsorted", "*.crow")).ToArray ();
testFiles = testFiles.Concat (Directory.GetFiles (@"Interfaces/GraphicObject", "*.crow")).ToArray ();
//testFiles = testFiles.Concat (Directory.GetFiles (@"Interfaces/basicTests", "*.crow")).ToArray ();
testFiles = testFiles.Concat (Directory.GetFiles (@"Interfaces/Container", "*.crow")).ToArray ();
TestList.Add ("new string");
NotifyValueChanged ("TestList", TestList);
return;
- } else if (e.Key == OpenTK.Input.Key.F2) {
+ } else if (e.Key == OpenTK.Input.Key.F4) {
GraphicObject w = CrowInterface.LoadInterface ("Interfaces/Divers/testWindow.goml");
w.DataSource = this;
return;
- } else if (e.Key != OpenTK.Input.Key.F3)
+ } else if (e.Key == OpenTK.Input.Key.F2)
+ idx--;
+ else if (e.Key == OpenTK.Input.Key.F3)
+ idx++;
+ else
return;
+
CrowInterface.ClearInterface ();
- idx++;
+
if (idx == testFiles.Length)
idx = 0;
+ else if (idx < 0)
+ idx = testFiles.Length - 1;
+
this.Title = testFiles [idx] + ". Press <F3> to cycle examples.";
GraphicObject obj = CrowInterface.LoadInterface(testFiles[idx]);
obj.DataSource = this;
RegisterForGraphicUpdate ();
}
}
- [XmlAttributeAttribute()][DefaultValue("White")]
- public override Fill Foreground {
- get { return base.Foreground;}
- set {base.Foreground = value;}
- }
#endregion
#region GraphicObject override
//if no layouting remains in queue for item, registre for redraw
if (RegisteredLayoutings == LayoutingType.None && bmp == null)
- RegisterForGraphicUpdate ();
+ Interface.CurrentInterface.EnqueueForRepaint (this);
return true;
}
//if no layouting remains in queue for item, registre for redraw
if (RegisteredLayoutings == LayoutingType.None && bmp == null)
- this.RegisterForGraphicUpdate ();
+ Interface.CurrentInterface.EnqueueForRepaint (this);
return true;
}
if (value == _textAlignment)
return;
_textAlignment = value;
- RegisterForRedraw ();
+ RegisterForGraphicUpdate ();
NotifyValueChanged ("TextAlignment", _textAlignment);
}
}
lines = getLines;
NotifyValueChanged ("Text", _text);
- this.RegisterForGraphicUpdate ();
+ RegisterForGraphicUpdate ();
}
}
[XmlAttributeAttribute][DefaultValue(false)]
SelBegin = new Point(0,0);
SelRelease = new Point (lines.LastOrDefault ().Length, lines.Count-1);
- RegisterForGraphicUpdate ();
+ RegisterForRedraw ();
}
public override void onUnfocused (object sender, EventArgs e)
{
SelBegin = -1;
SelRelease = -1;
- RegisterForGraphicUpdate ();
+ RegisterForRedraw ();
}
public override void onMouseMove (object sender, MouseMoveEventArgs e)
{
updatemouseLocalPos (e.Position);
- RegisterForGraphicUpdate();
+ RegisterForRedraw();
}
public override void onMouseDown (object sender, MouseButtonEventArgs e)
{
SelBegin = -1;
SelRelease = -1;
SelectionInProgress = true;
- RegisterForGraphicUpdate();//TODO:should put it in properties
+ RegisterForRedraw();//TODO:should put it in properties
}
//done at the end to set 'hasFocus' value after testing it
updatemouseLocalPos (e.Position);
SelectionInProgress = false;
- RegisterForGraphicUpdate ();
+ RegisterForRedraw ();
}
#endregion
minValue = value;
NotifyValueChanged ("Minimum", minValue);
- RegisterForGraphicUpdate ();
+ RegisterForRedraw ();
}
}
[XmlAttributeAttribute()][DefaultValue(100.0)]
maxValue = value;
NotifyValueChanged ("Maximum", maxValue);
- RegisterForGraphicUpdate ();
+ RegisterForRedraw ();
}
}
[XmlAttributeAttribute()][DefaultValue(1.0)]
smallStep = value;
NotifyValueChanged ("SmallIncrement", smallStep);
- RegisterForGraphicUpdate ();
+ RegisterForRedraw ();
}
}
[XmlAttributeAttribute()][DefaultValue(5.0)]
bigStep = value;
NotifyValueChanged ("LargeIncrement", bigStep);
- RegisterForGraphicUpdate ();
+ RegisterForRedraw ();
}
}
[XmlAttributeAttribute()][DefaultValue(0.0)]
else
_scrollX = value;
NotifyValueChanged("ScrollX", _scrollX);
- RegisterForGraphicUpdate ();
+ RegisterForRedraw ();
Scrolled.Raise (this, new ScrollingEventArgs (Orientation.Horizontal));
}
}
else
_scrollY = value;
NotifyValueChanged("ScrollY", _scrollY);
- RegisterForGraphicUpdate ();
+ RegisterForRedraw ();
Scrolled.Raise (this, new ScrollingEventArgs (Orientation.Vertical));
}
}
if (_cursorColor == value)
return;
_cursorColor = value;
- RegisterForGraphicUpdate ();
+ RegisterForRedraw ();
NotifyValueChanged ("CursorColor", _cursorColor);
}
}
if (_cursorSize == value)
return;
_cursorSize = value;
- RegisterForLayouting (LayoutingType.Sizing);
RegisterForGraphicUpdate ();
NotifyValueChanged ("CursorSize", _cursorSize);
}
(Children [selectedTab] as TabItem).IsSelected = true;
NotifyValueChanged ("SelectedTab", selectedTab);
- RegisterForGraphicUpdate ();
+ RegisterForRedraw ();
}
}
[XmlAttributeAttribute()][DefaultValue(22)]
//if no layouting remains in queue for item, registre for redraw
if (RegisteredLayoutings == LayoutingType.None && bmp == null)
- RegisterForGraphicUpdate ();
+ Interface.CurrentInterface.EnqueueForRepaint (this);
return true;
}
set
{
base.HasFocus = value;
- RegisterForGraphicUpdate();
+ RegisterForRedraw();
}
}
default:
break;
}
- if (Width < 0)
- RegisterForLayouting (LayoutingType.Width);
- if (Height < 0)
- RegisterForLayouting (LayoutingType.Height);
RegisterForGraphicUpdate();
}
public override void onKeyPress (object sender, KeyPressEventArgs e)
SelRelease = -1;
SelBegin = new Point(CurrentColumn, SelBegin.Y);
- if (Width < 0)
- RegisterForLayouting (LayoutingType.Width);
- if (Height < 0)
- RegisterForLayouting (LayoutingType.Height);
RegisterForGraphicUpdate();
}
#endregion
if (horizontalStretch == value)
return;
horizontalStretch = value;
- RegisterForGraphicUpdate ();
+ RegisterForRedraw ();
NotifyValueChanged ("HorizontalStretch", horizontalStretch);
}
}
if (verticalStretch == value)
return;
verticalStretch = value;
+ RegisterForRedraw ();
NotifyValueChanged ("VerticalStretch", verticalStretch);
-
}
}
[XmlAttributeAttribute ()]
return;
RegisterForGraphicUpdate ();
- this.RegisterForLayouting (LayoutingType.Sizing);
-
_text = value;
values.Add (_value);
while (values.Count > nbValues)
values.RemoveAt (0);
- RegisterForGraphicUpdate ();
+ RegisterForRedraw ();
}
public Trend ()
nbValues = value;
NotifyValueChanged ("NbValues", minValue);
- RegisterForGraphicUpdate ();
+ RegisterForRedraw ();
}
}
[XmlAttributeAttribute()][DefaultValue(0.0)]
minValue = value;
NotifyValueChanged ("Minimum", minValue);
- RegisterForGraphicUpdate ();
+ RegisterForRedraw ();
}
}
[XmlAttributeAttribute()][DefaultValue(100.0)]
maxValue = value;
NotifyValueChanged ("Maximum", maxValue);
- RegisterForGraphicUpdate ();
+ RegisterForRedraw ();
}
}
[XmlAttributeAttribute()][DefaultValue(20.0)]
return;
lowThresholdFill = value;
NotifyValueChanged ("LowThresholdFill", lowThresholdFill);
- RegisterForGraphicUpdate ();
+ RegisterForRedraw ();
}
}
[XmlAttributeAttribute()][DefaultValue("DarkGreen")]
return;
highThresholdFill = value;
NotifyValueChanged ("HighThresholdFill", highThresholdFill);
- RegisterForGraphicUpdate ();
+ RegisterForRedraw ();
}
}
protected override void onDraw (Cairo.Context gr)