From: Jean-Philippe Bruyère Date: Mon, 12 Jul 2021 06:27:08 +0000 (+0200) Subject: dont use solidBackground=true on windows, Stack and Template cached by default X-Git-Tag: v0.9.5-beta~9 X-Git-Url: https://git.osiis.dedyn.io/?a=commitdiff_plain;h=4181ca7888b9d544c12abb67046c445567b682cf;p=jp%2Fcrow.git dont use solidBackground=true on windows, Stack and Template cached by default --- diff --git a/Crow/Default.style b/Crow/Default.style index 80131bce..8a6d3e6e 100644 --- a/Crow/Default.style +++ b/Crow/Default.style @@ -328,7 +328,6 @@ MessageBox, Popper, Slider, Spinner, TextBox, NumericControl { Margin="0"; BubbleMouseEvent="MouseWheel|Keyboard"; } - -//TemplatedControl, GenericStack { -// CacheEnabled="true"; -//} \ No newline at end of file +TemplatedControl, GenericStack { + CacheEnabled="true"; +} \ No newline at end of file diff --git a/Crow/src/Interface.cs b/Crow/src/Interface.cs index 44f0a786..dece83e2 100644 --- a/Crow/src/Interface.cs +++ b/Crow/src/Interface.cs @@ -1098,7 +1098,17 @@ namespace Crow ctx.Fill (); ctx.Operator = Operator.Over; } - public bool SolidBackground = true; + bool solidBackground = false; + public bool SolidBackground { + get => solidBackground; + set { + if (Environment.OSVersion.Platform == PlatformID.Unix) + solidBackground = value; + else + Debug.WriteLine ("SolidBackground property only available on unix."); + } + } + /// Clipping Rectangles drive the drawing process. For compositing, each object under a clip rectangle should be /// repainted. If it contains also clip rectangles, its cache will be update, or if not cached a full redraw will take place @@ -1992,10 +2002,9 @@ namespace Crow } public Rectangle ClientRectangle => clientRectangle; - public Interface HostContainer { - get { return this; } - } - public Rectangle getSlot () => ClientRectangle; + public Interface HostContainer => this; + + public Rectangle getSlot () => ClientRectangle; public void ChildrenLayoutingConstraints(ILayoutable layoutable, ref LayoutingType layoutType){ } #endregion } diff --git a/Samples/ShowCase/ui/showcase.crow b/Samples/ShowCase/ui/showcase.crow index 431745f9..409ddd9d 100644 --- a/Samples/ShowCase/ui/showcase.crow +++ b/Samples/ShowCase/ui/showcase.crow @@ -59,7 +59,7 @@ - + - +