Ejemplo n.º 1
0
			public RenderState(RenderState other)
			{
				this.parent = other.parent;
				this.vertTextIndex = other.vertTextIndex.Clone() as int[];
				this.vertIconIndex = other.vertIconIndex;
				this.offset = other.offset;
				this.elemIndex = other.elemIndex;
				this.lineIndex = other.lineIndex;

				this.fontIndex = other.fontIndex;
				this.font = other.font;
				this.color = other.color;

				this.lineBeginX = other.lineBeginX;
				this.lineWidth = other.lineWidth;
				this.lineAvailWidth = other.lineAvailWidth;
				this.lineHeight = other.lineHeight;
				this.lineBaseLine = other.lineBaseLine;
				this.lineAlign = other.lineAlign;

				this.curElemOffset = other.curElemOffset;
				this.curElemVertTextIndex = other.curElemVertTextIndex;
				this.curElemVertIconIndex = other.curElemVertIconIndex;
				this.curElemWrapIndex = other.curElemWrapIndex;
				this.curElemText = other.curElemText;
			}
Ejemplo n.º 2
0
		public FormattedText(FormattedText other)
		{
			this.sourceText = other.sourceText;
			this.icons		= other.icons != null ? (Icon[])other.icons.Clone() : null;
			this.flowAreas	= other.flowAreas != null ? (FlowArea[])other.flowAreas.Clone() : null;
			this.fonts		= other.fonts != null ? (ContentRef<Font>[])other.fonts.Clone() : null;
			this.maxWidth	= other.maxWidth;
			this.maxHeight	= other.maxHeight;
			this.wrapMode	= other.wrapMode;
			this.lineAlign = other.lineAlign;

			this.ApplySource(this.sourceText);
		}
Ejemplo n.º 3
0
			public RenderState(FormattedText parent)
			{
				this.parent = parent;
				this.vertTextIndex = new int[this.parent.fonts != null ? this.parent.fonts.Length : 0];
				this.font = (this.parent.fonts != null && this.parent.fonts.Length > 0) ? this.parent.fonts[0].Res : null;
				this.color = ColorRgba.White;
				this.lineAlign = parent.lineAlign;

				this.PeekLineStats();
				this.offset.X = this.lineBeginX;
			}