コード例 #1
0
        public PedidosPage()
        {
            InitializeComponent();



            ThemeManager.ThemeName = Themes.Light;

            ThemeManager.Theme.HeaderCustomizer.BackgroundColor = Color.FromRgb(187, 228, 208);
            ThemeFontAttributes myFont = new ThemeFontAttributes("Blue",
                                                                 ThemeFontAttributes.FontSizeFromNamedSize(NamedSize.Medium),
                                                                 FontAttributes.Bold, Color.Black);

            ThemeManager.Theme.HeaderCustomizer.Font = myFont;

            ThemeManager.Theme.CellCustomizer.SelectionColor = Color.FromRgb(186, 220, 225);
            ThemeFontAttributes myFont1 = new ThemeFontAttributes("Yellow",
                                                                  ThemeFontAttributes.FontSizeFromNamedSize(NamedSize.Medium),
                                                                  FontAttributes.None, Color.Black);

            ThemeManager.Theme.CellCustomizer.Font = myFont1;


            //grid.SortMode = GridSortMode.Multiple;

            //grid.Columns["num"].SortOrder = DevExpress.Data.ColumnSortOrder.Descending;
            //grid.Columns["num"].SortIndex = 0;

            //grid.Columns["codcli"].SortOrder = DevExpress.Data.ColumnSortOrder.Descending;
            //grid.Columns["codcli"].SortIndex = 1;
        }
コード例 #2
0
        public ObjectListView(InvoiceViewModel viewModel)
        {
            InitializeComponent();

            devgrid.CustomUnboundColumnData += (object sender, DevExpress.Mobile.DataGrid.GridColumnDataEventArgs e) =>
            {
                if (e.Column.FieldName == "IncButton")
                {
                    e.Value = ImageSource.FromResource("ShoppingApp.Resources.IncIcon.png");
                }

                if (e.Column.FieldName == "DecButton")
                {
                    e.Value = ImageSource.FromResource("ShoppingApp.Resources.DecIcon.png");
                }
            };

            invoiceViewModel = viewModel;
            BindingContext   = invoiceViewModel;

            ThemeManager.ThemeName = Themes.Light;

            // Header customization.
            ThemeManager.Theme.HeaderCustomizer.BackgroundColor = Color.LightBlue;//FromRgb(187, 228, 208);
            ThemeFontAttributes myFont = new ThemeFontAttributes("Verdana",
                                                                 ThemeFontAttributes.FontSizeFromNamedSize(NamedSize.Large),
                                                                 FontAttributes.None, Color.Black);

            ThemeManager.Theme.HeaderCustomizer.Font = myFont;


            // Cell customization.
            ThemeManager.Theme.CellCustomizer.SelectionColor = Color.LightGray;//.FromRgb(186, 220, 225);
            ThemeFontAttributes myFont1 = new ThemeFontAttributes("Verdana",
                                                                  ThemeFontAttributes.FontSizeFromNamedSize(NamedSize.Medium),
                                                                  FontAttributes.None, Color.Black);

            ThemeManager.Theme.CellCustomizer.Font = myFont1;


            // Various customization.
            ThemeManager.Theme.TotalSummaryCustomizer.BackgroundColor = Color.LightGreen;//.FromRgb(163, 162, 168);
            ThemeFontAttributes myFont2 = new ThemeFontAttributes("Verdana",
                                                                  ThemeFontAttributes.FontSizeFromNamedSize(NamedSize.Default),
                                                                  FontAttributes.None, Color.Black);

            ThemeManager.Theme.TotalSummaryCustomizer.Font = myFont2;
            ThemeManager.Theme.NewItemRowCustomizer.Font   = myFont2;


            ThemeManager.RefreshTheme();
        }
コード例 #3
0
ファイル: MainPage.xaml.cs プロジェクト: rikace/devConf2017
        private void ConfigureTheme()
        {
            ThemeManager.ThemeName = Themes.Light;

            // Header customization.
            ThemeManager.Theme.HeaderCustomizer.BackgroundColor = Color.FromRgb(30, 150, 170);
            ThemeManager.Theme.HeaderCustomizer.Font            = new ThemeFontAttributes("Verdana",
                                                                                          ThemeFontAttributes.FontSizeFromNamedSize(NamedSize.Medium),
                                                                                          FontAttributes.None, Color.White);
            // Cell customization.
            ThemeManager.Theme.CellCustomizer.Font = new ThemeFontAttributes("Verdana",
                                                                             ThemeFontAttributes.FontSizeFromNamedSize(NamedSize.Medium),
                                                                             FontAttributes.None, Color.Black);

            ThemeManager.RefreshTheme();
        }
コード例 #4
0
        public PatientObservationsPage() : base()
        {
            InitializeComponent();

            ThemeManager.ThemeName = Themes.Light;

            var headerFont = new ThemeFontAttributes(Font.Default.FontFamily, Device.GetNamedSize(NamedSize.Micro, typeof(Label)), FontAttributes.None, Color.Gray);

            ThemeManager.Theme.HeaderCustomizer.Font             = headerFont;
            ThemeManager.Theme.HeaderCustomizer.Padding          = 0;
            ThemeManager.Theme.CellCustomizer.SelectionColor     = Color.White;
            ThemeManager.Theme.CellCustomizer.SelectionFontColor = Color.Black;
            var cellFont = new ThemeFontAttributes(Font.Default.FontFamily, Device.GetNamedSize(NamedSize.Small, typeof(Label)), FontAttributes.None, Color.Black);

            ThemeManager.Theme.CellCustomizer.Padding = 0;
            ThemeManager.Theme.CellCustomizer.Font    = cellFont;
            ThemeManager.RefreshTheme();
        }