using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Runtime.InteropServices; namespace Yaulw.Win32 { /// /// uxTheme.dll and dwmapi.dll Entry Points * http://pinvoke.net/ * /// public static class uxDwm { /// /// Obtains a value that indicates whether Desktop Window Manager (DWM) composition is enabled /// /// TRUE if DWM composition is enabled; otherwise, FALSE /// If this function succeeds, it returns S_OK. Otherwise, it returns an HRESULT error code [DllImport("dwmapi.dll")] extern public static long DwmIsCompositionEnabled(ref bool pfEnabled); /// /// Reports whether the current application's user interface displays using visual styles /// /// TRUE, if the application has a visual style applied. FALSE otherwise [DllImport("uxTheme.dll")] extern public static bool IsAppThemed(); } }