Exemple #1
0
        public static void SetDefaultAppearance()
        {
            WindowsFormsSettings.SetDPIAware();
            WindowsFormsSettings.EnableFormSkins();
            WindowsFormsSettings.AllowPixelScrolling = DefaultBoolean.True;
            WindowsFormsSettings.ScrollUIMode        = ScrollUIMode.Touch;
            ((UserLookAndFeelDefault)UserLookAndFeelDefault.Default).LoadSettings(() =>
            {
                var skinCreator = new SkinBlobXmlCreator("HybridApp", "PreciousUI.SkinData.", typeof(Program).Assembly, null);
                SkinManager.Default.RegisterSkin(skinCreator);
                SplashScreenManager.RegisterUserSkin(skinCreator);
            });
            WindowsFormsSettings.DefaultFont     = PrimaryFont;
            WindowsFormsSettings.DefaultMenuFont = PrimaryFont;
            UserLookAndFeel.Default.SetSkinStyle("HybridApp");
            Image caption = GetFormCaptionImage(PrimaryColor);

            FormSkins.GetSkin(UserLookAndFeelDefault.Default)[FormSkins.SkinFormCaption].SetActualImage(caption, true);
            FormSkins.GetSkin(UserLookAndFeelDefault.Default)[FormSkins.SkinFormFrameBottom].SetActualImage(caption, true);
            FormSkins.GetSkin(UserLookAndFeelDefault.Default)[FormSkins.SkinFormFrameRight].SetActualImage(caption, true);
            FormSkins.GetSkin(UserLookAndFeelDefault.Default)[FormSkins.SkinFormFrameLeft].SetActualImage(caption, true);
        }
Exemple #2
0
        static void Main()
        {
            DataDirectoryHelper.SetWebBrowserMode();
            DevExpress.XtraEditors.WindowsFormsSettings.ApplyDemoSettings();
            SkinManager.EnableFormSkins();
            UserSkins.BonusSkins.Register();
            AppearanceObject.DefaultFont = new Font("Segoe UI", 8.25f);
            SkinBlobXmlCreator skinCreator = new SkinBlobXmlCreator("MetroBlack",
                                                                    "DevExpress.RealtorWorld.Win.SkinData.", typeof(Program).Assembly, null);

            SkinManager.Default.RegisterSkin(skinCreator);
            AsyncAdornerBootStrapper.RegisterLookAndFeel(
                "MetroBlack", "DevExpress.RealtorWorld.Win.SkinData.", typeof(Program).Assembly);
            LookAndFeel.UserLookAndFeel.Default.SetSkinStyle("Metropolis");
            CultureInfo demoCI = (CultureInfo)Application.CurrentCulture.Clone();

            demoCI.NumberFormat.CurrencySymbol = "$";
            SplashScreenManager.RegisterUserSkin(skinCreator);
            Application.CurrentCulture = demoCI;
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);
            DataHelper.CreateWmiService();
            Application.Run(new frmMain());
        }