New tests.
[mono.git] / mcs / class / Managed.Windows.Forms / System.Windows.Forms / Theme.cs
index e4e61e7a9ffad441bca6d7f5a54167b544fddbea..e4154e726f197b2595dc28fa8aa0a2ce69a34da2 100644 (file)
@@ -202,6 +202,7 @@ namespace System.Windows.Forms
 #else
                        default_font = new Font (FontFamily.GenericSansSerif, 8.25f);
 #endif
+                       syscolors = null;
                }
 
                private void SetSystemColors (KnownColor kc, Color value)
@@ -496,7 +497,7 @@ namespace System.Windows.Forms
                
                public virtual Size MenuButtonSize {
                        get {
-                               return new Size(18, 18);
+                               return XplatUI.MenuButtonSize;
                        }
                }
 
@@ -575,7 +576,7 @@ namespace System.Windows.Forms
                        else return value;
                }
 
-               [MonoTODO("Figure out where to point for My Network Places")]
+               [MonoInternalNote ("Figure out where to point for My Network Places")]
                public virtual string Places(UIIcon index) {
                        switch (index) {
                                case UIIcon.PlacesRecentDocuments: {
@@ -745,6 +746,8 @@ namespace System.Windows.Forms
                public abstract void ComboBoxDrawNormalDropDownButton (ComboBox comboBox, Graphics g, Rectangle clippingArea, Rectangle area, ButtonState state);
                public abstract bool ComboBoxNormalDropDownButtonHasTransparentBackground (ComboBox comboBox, ButtonState state);
                public abstract bool ComboBoxDropDownButtonHasHotElementStyle (ComboBox comboBox);
+               public abstract void ComboBoxDrawBackground (ComboBox comboBox, Graphics g, Rectangle clippingArea, FlatStyle style);
+               public abstract bool CombBoxBackgroundHasHotElementStyle (ComboBox comboBox);
                #endregion      // ComboBox
 
                #region Control
@@ -775,9 +778,11 @@ namespace System.Windows.Forms
                public abstract void DataGridPaint (PaintEventArgs pe, DataGrid grid);
                public abstract void DataGridPaintCaption (Graphics g, Rectangle clip, DataGrid grid);
                public abstract void DataGridPaintColumnHeaders (Graphics g, Rectangle clip, DataGrid grid);
+               public abstract void DataGridPaintColumnHeader (Graphics g, Rectangle bounds, DataGrid grid, int col);
                public abstract void DataGridPaintRowContents (Graphics g, int row, Rectangle row_rect, bool is_newrow, Rectangle clip, DataGrid grid);
                public abstract void DataGridPaintRowHeader (Graphics g, Rectangle bounds, int row, DataGrid grid);
                public abstract void DataGridPaintRowHeaderArrow (Graphics g, Rectangle bounds, DataGrid grid);
+               public abstract void DataGridPaintRowHeaderStar (Graphics g, Rectangle bounds, DataGrid grid);
                public abstract void DataGridPaintParentRows (Graphics g, Rectangle bounds, DataGrid grid);
                public abstract void DataGridPaintParentRow (Graphics g, Rectangle bounds, DataGridDataSource row, DataGrid grid);
                public abstract void DataGridPaintRows (Graphics g, Rectangle cells, Rectangle clip, DataGrid grid);
@@ -805,9 +810,11 @@ namespace System.Windows.Forms
 #endif
 
                #region DateTimePicker
-
                public abstract void DrawDateTimePicker(Graphics dc, Rectangle clip_rectangle, DateTimePicker dtp);
-
+               public abstract bool DateTimePickerBorderHasHotElementStyle { get; }
+               public abstract Rectangle DateTimePickerGetDropDownButtonArea (DateTimePicker dateTimePicker);
+               public abstract Rectangle DateTimePickerGetDateArea (DateTimePicker dateTimePicker);
+               public abstract bool DateTimePickerDropDownButtonHasHotElementStyle { get; }
                #endregion      // DateTimePicker
 
                #region GroupBox
@@ -939,8 +946,6 @@ namespace System.Windows.Forms
                public abstract Point TabControlImagePadding { get; }
                public abstract int TabControlScrollerWidth { get; }
 
-               public abstract Rectangle TabControlGetLeftScrollRect (TabControl tab);
-               public abstract Rectangle TabControlGetRightScrollRect (TabControl tab);
                public abstract Rectangle TabControlGetDisplayRectangle (TabControl tab);
                public abstract Rectangle TabControlGetPanelRect (TabControl tab);
                public abstract Size TabControlGetSpacing (TabControl tab);
@@ -979,6 +984,7 @@ namespace System.Windows.Forms
                #region BalloonWindow
 #if NET_2_0
                public abstract void ShowBalloonWindow (IntPtr handle, int timeout, string title, string text, ToolTipIcon icon);
+               public abstract void HideBalloonWindow (IntPtr handle);
                public abstract void DrawBalloonWindow (Graphics dc, Rectangle clip, NotifyIcon.BalloonWindow control);
                public abstract Rectangle BalloonWindowRect (NotifyIcon.BalloonWindow control);
 #endif
@@ -1010,39 +1016,20 @@ namespace System.Windows.Forms
                public abstract void TreeViewDrawNodePlusMinus (TreeView treeView, TreeNode node, Graphics dc, int x, int middle);
                #endregion
 
-               public virtual void DrawManagedWindowDecorations (Graphics dc, Rectangle clip, InternalWindowManager wm)
-               {
-                       // Just making virtual for now so all the themes still build.
-               }
-
-               public virtual int ManagedWindowTitleBarHeight (InternalWindowManager wm)
-               {
-                       // Just making virtual for now so all the themes still build.
-                       return 15;
-               }
-
-               public virtual int ManagedWindowBorderWidth (InternalWindowManager wm)
-               {
-                       // Just making virtual for now so all the themes still build.
-                       return 3;
-               }
-
-               public virtual int ManagedWindowIconWidth (InternalWindowManager wm)
-               {
-                       // Just making virtual for now so all the themes still build.
-                       return ManagedWindowTitleBarHeight (wm) - 5;
-               }
-
-               public virtual Size ManagedWindowButtonSize (InternalWindowManager wm)
-               {
-                       // Just making virtual for now so all the themes still build.
-                       return new Size (10, 10);
-               }
-
-               public virtual void ManagedWindowSetButtonLocations (InternalWindowManager wm)
-               {
-                       // Just making virtual for now so all the themes still build.
-               }
+               #region Managed window
+               public abstract void DrawManagedWindowDecorations (Graphics dc, Rectangle clip, InternalWindowManager wm);
+               public abstract int ManagedWindowTitleBarHeight (InternalWindowManager wm);
+               public abstract int ManagedWindowBorderWidth (InternalWindowManager wm);
+               public abstract int ManagedWindowIconWidth (InternalWindowManager wm);
+               public abstract Size ManagedWindowButtonSize (InternalWindowManager wm);
+               public abstract void ManagedWindowSetButtonLocations (InternalWindowManager wm);
+               public abstract Rectangle ManagedWindowGetTitleBarIconArea (InternalWindowManager wm);
+               public abstract Size ManagedWindowGetMenuButtonSize (InternalWindowManager wm);
+               public abstract bool ManagedWindowTitleButtonHasHotElementStyle (TitleButton button, Form form);
+               public abstract void ManagedWindowDrawMenuButton (Graphics dc, TitleButton button, Rectangle clip, InternalWindowManager wm);
+               public abstract void ManagedWindowOnSizeInitializedOrChanged (Form form);
+               public const int ManagedWindowSpacingAfterLastTitleButton = 2;
+               #endregion
 
                #region ControlPaint Methods
                public abstract void CPDrawBorder (Graphics graphics, Rectangle bounds, Color leftColor, int leftWidth,