2009/9/9 Stefanos A. <[email protected]>: > Την Wed, 09 Sep 2009 23:14:07 +0300,ο(η) Christian Hoff > <[email protected]> έγραψε: > >> Bingo! It's the foster window that enables theming. At least it worked >> on a XP machine at school which I contaminated with Gtk# :-) . I >> attached the new test application which should now work at least on XP >> (the visual styles hack never worked on my Windows 7 machine). Again, it >> would be great if you could give it a try on your machine to ensure it >> works properly before we commit this. >> > > Confirming success on Vista x86! > > Additionally, there is no need to keep the window lying around. Calling > DestroyWindow immediately doesn't seem to be causing any problems. > > [DllImport ("user32.dll", EntryPoint="DestroyWindow", > CharSet=CharSet.Unicode, CallingConvention=CallingConvention.StdCall)] > internal extern static bool Win32DestroyWindow(IntPtr window); > > [...] > > // No idea why we need to create that window, but it enables visual styles > on the Windows platform > IntPtr window = Win32CreateWindow (WS_EX_TOOLWINDOW, "static", "Foster > Parent Window", WS_OVERLAPPEDWINDOW, 0, 0, 0, 0, IntPtr.Zero, IntPtr.Zero, > IntPtr.Zero, IntPtr.Zero); > Win32DestroyWindow(window); > _______________________________________________ > Mono-devel-list mailing list > [email protected] > http://lists.ximian.com/mailman/listinfo/mono-devel-list >
Bravo Folks!! This is a much better "hack" than the Windows.Forms call. Jae _______________________________________________ Gtk-sharp-list maillist - [email protected] http://lists.ximian.com/mailman/listinfo/gtk-sharp-list
