From b24beece9ed58b2700dd5d2d56fa45e446567ab0 Mon Sep 17 00:00:00 2001 From: jpbruyere Date: Tue, 19 Jul 2016 03:35:12 +0200 Subject: lots of unordered changes, I commited all in a devel branch, which will be the programming branch --- src/Interface.cs | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) (limited to 'src/Interface.cs') diff --git a/src/Interface.cs b/src/Interface.cs index d0c385e7..b8426e6f 100644 --- a/src/Interface.cs +++ b/src/Interface.cs @@ -30,6 +30,15 @@ using Cairo; namespace Crow { + /// + /// The Interface Class is the top container of the application. + /// It provides the Dirty bitmap and zone of the interface to be drawn on screen + /// + /// The Interface contains : + /// - rendering and layouting queues and logic. + /// - helpers to load XML interfaces files + /// - global constants and variables of CROW + /// public class Interface : ILayoutable { #region CTOR @@ -58,6 +67,7 @@ namespace Crow public static int TabSize = 4; public static string LineBreak = "\r\n"; + //TODO: shold be declared in graphicObject public static bool FocusOnHover = false; /// Time to wait in millisecond before starting repeat loop public static int DeviceRepeatDelay = 600; @@ -68,11 +78,18 @@ namespace Crow public static bool DesignerMode = false; /// Threshold to catch borders for sizing public static int BorderThreshold = 5; + /// Disable caching for a widget if this threshold is reached public const int MaxCacheSize = 2048; + /// Above this count, the layouting is discard for the widget and it + /// will not be rendered on screen public const int MaxLayoutingTries = 50; + /// Global font rendering settings for Cairo public static FontOptions FontRenderingOptions; #endregion + /// + /// The layouting queue contains layouting commands + /// public Queue LayoutingQueue; public Queue GraphicUpdateQueue = new Queue(); public string Clipboard; @@ -98,6 +115,10 @@ namespace Crow } #region default values loading helpers + /// Default values of properties from GraphicObjects are retrieve from XML Attributes. + /// The reflexion process used to retrieve those values being very slow, it is compiled in MSIL + /// and injected as a dynamic method referenced in the DefaultValuesLoader Dictionnary. + /// The compilation is done on the first object instancing, and is also done for custom widgets public delegate void loadDefaultInvoker(object instance); public static Dictionary DefaultValuesLoader = new Dictionary(); #endregion -- cgit v1.3.1-4-g156e