[Mono-dev] Patches for mono-winforms

Steven Boswell II ulatekh at yahoo.com
Mon Jul 23 00:39:35 UTC 2012


OK, here's a much simpler patch.
It draws a mixed-mode checkbox with a grey checkmark.
Let me know if there's any problems.

Steven Boswell


________________________________
 From: Steven Boswell II <ulatekh at yahoo.com>
To: "mono-devel-list at lists.ximian.com" <mono-devel-list at lists.ximian.com> 
Sent: Sunday, July 22, 2012 5:22 PM
Subject: Re: [Mono-dev] Patches for mono-winforms
 

Ah...without EnableVisualStyles(), an indeterminate checkbox is a _grey_ check mark in .NET under MS Windows.
How about if I redo my change to draw the checkmark in grey?  Would you accept that patch?



________________________________
 From: Steven Boswell II <ulatekh at yahoo.com>
To: "mono-devel-list at lists.ximian.com" <mono-devel-list at lists.ximian.com> 
Sent: Sunday, July 22, 2012 5:03 PM
Subject: Re: [Mono-dev] Patches for mono-winforms
 

Do you mean Application.EnableVisualStyles()?  Our application calls that in its Main() method.

I know I wasn't seeing the indeterminate checkbox when running Mono under Linux, which is why I thought to attempt this change in the first place.  Are you saying the indeterminate checkbox looks like the checked checkbox when Application.EnableVisualStyles() isn't called?


I use Mono under Linux to write code that's shipped running .NET under MS Windows, but Mono lets me use a development environment (Fedora Core 16) that doesn't drive me up the wall.  So my experience with Mono is somewhat limited to that.


Steven Boswell



________________________________
 From: Jonathan Pobst <monkey at jpobst.com>
To: Steven Boswell II <ulatekh at yahoo.com> 
Cc: "mono-devel-list at lists.ximian.com" <mono-devel-list at lists.ximian.com> 
Sent: Sunday, July 22, 2012 4:50 PM
Subject: Re: [Mono-dev] Patches for mono-winforms
 
Please note that this is controlled by Application.EnableVisualThemes.

Mono mimics the Win32 Classic look that the .NET Framework produces when 
you do not call EnableVisualThemes.  (Note that if you created a project 
in VS or something, this call was automatically added in your Program.cs.)

When EnableVisualThemes is called, the rendering should be controlled by 
the OS, so you will see the filled square on Windows 7, but XP is 
probably different.

I think Visual Styles work when Mono runs on Windows.  There were some 
attempts to write it for GNOME and maybe Mac, but they were never completed.

On 7/22/2012 1:57 PM, Steven Boswell II wrote:
> Enclosed is a patch that implements the drawing of mixed-mode
> checkboxes.  Before, Mono just drew the indeterminate state with a check
> mark.  Now, it's a blue box, which is closer to what .NET does.
>   (Technically,
 the patch uses the "highlight" color, which is a good
> choice until a more exact idea comes along).


_______________________________________________
Mono-devel-list mailing list
Mono-devel-list at lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list



_______________________________________________
Mono-devel-list mailing list
Mono-devel-list at lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.ximian.com/pipermail/mono-devel-list/attachments/20120722/aa657b2c/attachment-0001.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: mwf-13-ThemeWin32Classic-CPDrawMixedCheckBox.patch
Type: application/octet-stream
Size: 1337 bytes
Desc: not available
URL: <http://lists.ximian.com/pipermail/mono-devel-list/attachments/20120722/aa657b2c/attachment-0001.obj>


More information about the Mono-devel-list mailing list