diff --git a/pixelperfectengine/src/pixelperfectengine/system/lang/textparser.d b/pixelperfectengine/src/pixelperfectengine/system/lang/textparser.d index 725a84b..79e55fd 100644 --- a/pixelperfectengine/src/pixelperfectengine/system/lang/textparser.d +++ b/pixelperfectengine/src/pixelperfectengine/system/lang/textparser.d @@ -197,6 +197,24 @@ public class TextParserTempl(BitmapType = Bitmap8Bit) newFrmt.rowHeight = rowHeightStr.to!short; } catch (Exception e) { + } + switch (attributes.get("justify", null)) { + case "left": + newFrmt.formatFlags &= ~FormattingFlags.justifyMask; + break; + case "right": + newFrmt.formatFlags &= ~FormattingFlags.justifyMask; + newFrmt.formatFlags |= FormattingFlags.rightJustify; + break; + case "center": + newFrmt.formatFlags &= ~FormattingFlags.justifyMask; + newFrmt.formatFlags |= FormattingFlags.centerJustify; + break; + case "fill": + newFrmt.formatFlags &= ~FormattingFlags.justifyMask; + newFrmt.formatFlags |= FormattingFlags.fillEntireLine; + break; + default: break; } testFormatting(newFrmt); currTextBlock.formatting = currFrmt;