當前位置: 首頁>>代碼示例>>C#>>正文


C# Align類代碼示例

本文整理匯總了C#中Align的典型用法代碼示例。如果您正苦於以下問題:C# Align類的具體用法?C# Align怎麽用?C# Align使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。


Align類屬於命名空間,在下文中一共展示了Align類的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的C#代碼示例。

示例1: MarkdownTableBlockToken

 public MarkdownTableBlockToken(IMarkdownRule rule, string[] header, Align[] align, string[][] cells)
 {
     Rule = rule;
     Header = header;
     Align = align;
     Cells = cells;
 }
開發者ID:yonglehou,項目名稱:docfx,代碼行數:7,代碼來源:MarkdownTableBlockToken.cs

示例2: RtfTable

		public RtfTable(int rowCount, int colCount, float horizontalWidth, float fontSize)
		{
			_fontSize = fontSize;
			_alignment = Align.None;
			_margins = new Margins();
			_rowCount = rowCount;
			_colCount = colCount;
			_representativeList = new List<RtfTableCell>();
			_startNewPage = false;
			_titleRowCount = 0;
			_cellPadding = new Margins[_rowCount];
			if (_rowCount < 1 || _colCount < 1) {
				throw new Exception("The number of rows or columns is less than 1.");
			}
			
			// Set cell default width according to paper width
			_defaultCellWidth = horizontalWidth / (float)colCount;
			_cells = new RtfTableCell[_rowCount][];
			_rowHeight = new float[_rowCount];
			_rowKeepInSamePage = new bool[_rowCount];
			for (int i = 0; i < _rowCount; i++) {
				_cells[i] = new RtfTableCell[_colCount];
				_rowHeight[i] = 0F;
				_rowKeepInSamePage[i] = false;
				_cellPadding[i] = new Margins();
				for (int j = 0; j < _colCount; j++) {
					_cells[i][j] = new RtfTableCell(_defaultCellWidth, i, j, this);
				}
			}
		}
開發者ID:Karousos,項目名稱:EYE_Sampling,代碼行數:30,代碼來源:RtfTable.cs

示例3: AlignContainer

 public AlignContainer(Control Client, Point ClientSize, Align HorizontalAlign, Align VerticalAlign)
 {
     this._Client = Client;
     this._ClientSize = ClientSize;
     this._VerticalAlign = VerticalAlign;
     this._HorizontalAlign = HorizontalAlign;
 }
開發者ID:alexcmd,項目名稱:OpenTKGUI,代碼行數:7,代碼來源:AlignContainer.cs

示例4: ParseParams

        /// <summary>
        /// Parse slide parameters
        /// </summary>
        /// <param name="parameters"></param>
        private void ParseParams(string parameters)
        {
            if (parameters == null || parameters.Trim().Length == 0)
                return;

            // "shrink,squeeze,c" -> ["shrink","squeeze","c"]
            string[] parts = parameters.Replace(" ", "").Split(new char[] { ',' }, StringSplitOptions.RemoveEmptyEntries);

            foreach (string part in parts)
            {
                switch (part)
                {
                    case "t":
                        ContentAlign = Align.TOP;
                        break;
                    case "c":
                        ContentAlign = Align.CENTER;
                        break;
                    case "b":
                        ContentAlign = Align.BOTTOM;
                        break;
                    default:
                        break;
                }
            }
        }
開發者ID:blacker-cz,項目名稱:SimpleConverter,代碼行數:30,代碼來源:SlideSettings.cs

示例5: Start

	void Start()
	{
		ResetVelocities ();
		alignScript = GetComponent<Align> ();
		behaviour = GetComponents<SteeringBehavior> ();
		creature = GetComponent<Creature> ();
//		defaultY = transform.position.y;
	}
開發者ID:Emmanuel-Tsapekis,項目名稱:PetFactory,代碼行數:8,代碼來源:SteeringAgent.cs

示例6: Label

 public Label(string text, float fontSize, System.Drawing.Color fontColor, Window window)
     : base(window)
 {
     this.Name = "Label";
     Text = text;
     Alignment = Align.LEFT;
     Color = fontColor;
 }
開發者ID:maesse,項目名稱:CubeHags,代碼行數:8,代碼來源:Label.cs

示例7: Clear

		public override void Clear()
		{
			_memoized_size = _b0 = 0;
			_id = 0;
			_name = null;
			_align = Align.Left;
			_weights.Clear();
		}
開發者ID:Dataflow-Software,項目名稱:Dataflow.NET,代碼行數:8,代碼來源:MapTest.pb.cs

示例8: Text

 /// <summary>
 /// Creates a new Text object
 /// </summary>
 /// <param name="font"> The font to use for the Text </param>
 /// <param name="text"> The text to display </param>
 /// <param name="position"> The position of the Text </param>
 /// <param name="color"> The color of the Text </param>
 /// <param name="alignment"> The alignment of the Text </param>
 public Text(SpriteFont font, String text, Vector2 position, Color color, Align alignment)
 {
     Font = font;
     this.text = text;
     Position = position;
     TextColor = color;
     Alignment = alignment;
 }
開發者ID:Aaron-Durant,項目名稱:Asteroids2,代碼行數:16,代碼來源:Text.cs

示例9: Header

 public Header(string name, Align alignment, Align cellAlignment, int minimumLength, int maximumLength)
 {
     Name = name;
     Alignment = alignment;
     CellAlignment = cellAlignment;
     MinimumLength = minimumLength;
     MaximumLength = maximumLength;
 }
開發者ID:txdv,項目名稱:sharpmod,代碼行數:8,代碼來源:Header.cs

示例10: Label

 //bool wordwrap = false;
 public Label(string name, Vector2 position, string text, Color backColor, Color foreColor, int width, Align alignment)
     : base(name, position)
 {
     this.Text = text;
     this.BackColor = backColor;
     this.ForeColor = foreColor;
     this.alignment = alignment;
     this.Width = width;
 }
開發者ID:Layoric,項目名稱:xWinFormsLib,代碼行數:10,代碼來源:Label.cs

示例11: FromString

        public override Style FromString(string s)
        {
            Align result;
            if (!Enum.TryParse<Align>(s, true, out result))
                throw new Exception("Invalid horizontal-align value");

            this.Value = result;
            return this;
        }
開發者ID:Fedorm,項目名稱:core-master,代碼行數:9,代碼來源:HorizontalAlign.cs

示例12: LogicText

 public LogicText(string text, float fontSize, PointF location, SizeF size, Align alignment, Color color)
 {
     this.text = text;
     this.font = new Font(DefaultFamily, fontSize);
     this.Location = location;
     this.Size = size;
     this.alignment = alignment;
     this.ForeColor = color;
 }
開發者ID:BGCX261,項目名稱:ziliao-svn-to-git,代碼行數:9,代碼來源:LogicText.cs

示例13: RtfSection

		internal RtfSection(SectionStartEnd startEnd, RtfDocument doc)
		{
			ParentDocument = doc;
			_align = Align.None;
			PageOrientation = PaperOrientation.Portrait;
			StartEnd = startEnd;
			FooterPositionFromPageBottom = 720;
			_sectionFooter = null;
			_margins = new Margins();
		}
開發者ID:Karousos,項目名稱:EYE_Sampling,代碼行數:10,代碼來源:RtfSection.cs

示例14: RtfTableCell

		internal RtfTableCell(float width, int rowIndex, int colIndex)
			: base(true, true, false, true, false)
		{
			_width = width;
			_halign = Align.None;
			_valign = AlignVertical.Top;
			_borders = new Borders();
			_mergeInfo = null;
			_rowIndex = rowIndex;
			_colIndex = colIndex;
		}
開發者ID:Andrea,項目名稱:duality-withsvn-history,代碼行數:11,代碼來源:RtfTableCell.cs

示例15: FromString

        public override Style FromString(string s)
        {
            s = s.Trim();

            Align result;
            if (!Enum.TryParse<Align>(s, true, out result))
                throw new Exception("Invalid text-align value: " + s);
            
            this.Value = result;
            return this;
        }
開發者ID:Fedorm,項目名稱:core-master,代碼行數:11,代碼來源:TextAlign.cs


注:本文中的Align類示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。