コード例 #1
0
        FlowLayoutWidget GetMiddleRow()
        {
            FlowLayoutWidget container = new FlowLayoutWidget();

            container.HAnchor         = HAnchor.ParentLeftRight;
            container.VAnchor         = Agg.UI.VAnchor.ParentBottomTop;
            container.BackgroundColor = ActiveTheme.Instance.SecondaryBackgroundColor;

            FlowLayoutWidget topBottomContainer = new FlowLayoutWidget(FlowDirection.TopToBottom);

            topBottomContainer.AnchorAll();

            FlowLayoutWidget addContainer = new FlowLayoutWidget(FlowDirection.TopToBottom);

            addContainer.BackgroundColor = ActiveTheme.Instance.PrimaryBackgroundColor;
            addContainer.HAnchor         = Agg.UI.HAnchor.ParentLeftRight;

            TextWidget errorMessage = new TextWidget("Oops! Please select a setting first.", pointSize: 10);

            errorMessage.TextColor = ActiveTheme.Instance.SecondaryAccentColor;

            errorMessageContainer                 = new FlowLayoutWidget();
            errorMessageContainer.HAnchor         = Agg.UI.HAnchor.ParentLeftRight;
            errorMessageContainer.BackgroundColor = ActiveTheme.Instance.TransparentDarkOverlay;
            errorMessageContainer.Visible         = false;
            errorMessageContainer.Padding         = new BorderDouble(3);

            errorMessageContainer.AddChild(new HorizontalSpacer());
            errorMessageContainer.AddChild(errorMessage);
            errorMessageContainer.AddChild(new HorizontalSpacer());

            addSettingsContainer                 = new FlowLayoutWidget();
            addSettingsContainer.Padding         = new BorderDouble(3);
            addSettingsContainer.BackgroundColor = ActiveTheme.Instance.TransparentDarkOverlay;
            addSettingsContainer.HAnchor         = HAnchor.ParentLeftRight;

            PopulateAddSettingRow();

            addContainer.AddChild(addSettingsContainer);
            addContainer.AddChild(errorMessageContainer);

            settingsRowContainer         = new PresetListControl();
            settingsRowContainer.HAnchor = HAnchor.ParentLeftRight;

            LoadSettingsRows();

            topBottomContainer.AddChild(addContainer);
            topBottomContainer.AddChild(settingsRowContainer);

            container.AddChild(topBottomContainer);
            return(container);
        }
コード例 #2
0
        private FlowLayoutWidget GetMiddleRow()
        {
            FlowLayoutWidget container = new FlowLayoutWidget();

            container.HAnchor         = HAnchor.ParentLeftRight;
            container.VAnchor         = Agg.UI.VAnchor.ParentBottomTop;
            container.BackgroundColor = ActiveTheme.Instance.SecondaryBackgroundColor;
            container.Margin          = new BorderDouble(0, 3, 0, 0);

            presetListControl = new PresetListControl();

            foreach (SliceSettingsCollection collection in GetCollections())
            {
                presetListControl.AddChild(new PresetListItem(this.windowController, collection));
            }
            container.AddChild(presetListControl);

            return(container);
        }
コード例 #3
0
		private FlowLayoutWidget GetMiddleRow()
		{
			FlowLayoutWidget container = new FlowLayoutWidget();
			container.HAnchor = HAnchor.ParentLeftRight;
			container.VAnchor = Agg.UI.VAnchor.ParentBottomTop;
			container.BackgroundColor = ActiveTheme.Instance.SecondaryBackgroundColor;

			FlowLayoutWidget topBottomContainer = new FlowLayoutWidget(FlowDirection.TopToBottom);
			topBottomContainer.AnchorAll();

			FlowLayoutWidget addContainer = new FlowLayoutWidget(FlowDirection.TopToBottom);
			addContainer.BackgroundColor = ActiveTheme.Instance.PrimaryBackgroundColor;
			addContainer.HAnchor = Agg.UI.HAnchor.ParentLeftRight;

			TextWidget errorMessage = new TextWidget("Oops! Please select a setting first.", pointSize: 10);
			errorMessage.TextColor = ActiveTheme.Instance.SecondaryAccentColor;

			errorMessageContainer = new FlowLayoutWidget();
			errorMessageContainer.HAnchor = Agg.UI.HAnchor.ParentLeftRight;
			errorMessageContainer.BackgroundColor = ActiveTheme.Instance.TransparentDarkOverlay;
			errorMessageContainer.Visible = false;
			errorMessageContainer.Padding = new BorderDouble(3);

			errorMessageContainer.AddChild(new HorizontalSpacer());
			errorMessageContainer.AddChild(errorMessage);
			errorMessageContainer.AddChild(new HorizontalSpacer());

			addSettingsContainer = new FlowLayoutWidget();
			addSettingsContainer.Padding = new BorderDouble(3);
			addSettingsContainer.BackgroundColor = ActiveTheme.Instance.TransparentDarkOverlay;
			addSettingsContainer.HAnchor = HAnchor.ParentLeftRight;

			PopulateAddSettingRow();

			addContainer.AddChild(addSettingsContainer);
			addContainer.AddChild(errorMessageContainer);

			settingsRowContainer = new PresetListControl();
			settingsRowContainer.HAnchor = HAnchor.ParentLeftRight;

			LoadSettingsRows();

			topBottomContainer.AddChild(addContainer);
			topBottomContainer.AddChild(settingsRowContainer);

			container.AddChild(topBottomContainer);
			return container;
		}
コード例 #4
0
		private FlowLayoutWidget GetMiddleRow()
		{
			FlowLayoutWidget container = new FlowLayoutWidget();
			container.HAnchor = HAnchor.ParentLeftRight;
			container.VAnchor = Agg.UI.VAnchor.ParentBottomTop;
			container.BackgroundColor = ActiveTheme.Instance.SecondaryBackgroundColor;
			container.Margin = new BorderDouble(0, 3, 0, 0);

			presetListControl = new PresetListControl();

			foreach (SliceSettingsCollection collection in GetCollections())
			{
				presetListControl.AddChild(new PresetListItem(this.windowController, collection));
			}
			container.AddChild(presetListControl);

			return container;
		}