当前位置: 首页>>代码示例>>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;未经允许,请勿转载。