@@ -19,8 +19,8 @@ local Color = require(script.Color)
1919local FontFace = require (script .FontFace )
2020local GuiObjectPart = require (script .GuiObjectPart )
2121local LineJoinMode = require (script .LineJoinMode )
22- local HorizontalAlignment = require (script .HorizontalAlignment )
23- local VerticalAlignment = require (script .VerticalAlignment )
22+ local TextXAlignment = require (script .TextXAlignment )
23+ local TextYAlignment = require (script .TextYAlignment )
2424
2525local PluginGui = {}
2626
@@ -157,6 +157,22 @@ function PluginGui:newPluginGui(widgetGui)
157157 )
158158 listFrame :AddChild (alignmentCollapse :GetSectionFrame ()) -- add child to expanding VerticallyScalingListFrame
159159
160+ local yChoice = LabeledMultiChoice .new (
161+ " yChoice" , -- name suffix of gui object
162+ " Horizontal Alignment" , -- title text of the multi choice
163+ TextYAlignment , -- choices array
164+ 2 -- the starting index of the selection
165+ )
166+ yChoice :GetFrame ().Parent = alignmentCollapse :GetContentsFrame ()
167+
168+ local xChoice = LabeledMultiChoice .new (
169+ " xChoice" , -- name suffix of gui object
170+ " Vertical Alignment" , -- title text of the multi choice
171+ TextXAlignment , -- choices array
172+ 2 -- the starting index of the selection
173+ )
174+ xChoice :GetFrame ().Parent = alignmentCollapse :GetContentsFrame ()
175+
160176 local strokeCollapse = CollapsibleTitledSection .new ( -- Fonts collapse
161177 " strokeCollapse" , -- name suffix of the gui object
162178 " Stroke" , -- the text displayed beside the collapsible arrow
@@ -325,27 +341,37 @@ function PluginGui:newPluginGui(widgetGui)
325341 end )
326342
327343 colorTextChoice :SetValueChangedFunction (function (newIndex )
328- local color = Color [newIndex ].Color
329- CustomTextLabel :UpdateTextColor3 (color )
344+ local newValue = Color [newIndex ].Color
345+ CustomTextLabel :UpdateTextColor3 (newValue )
330346 end )
331347
332348 fontTextChoice :SetValueChangedFunction (function (newIndex )
333- local font = FontFace [newIndex ].Font
334- CustomTextLabel :UpdateFontFace (font )
349+ local newValue = FontFace [newIndex ].Font
350+ CustomTextLabel :UpdateFontFace (newValue )
351+ end )
352+
353+ yChoice :SetValueChangedFunction (function (newIndex )
354+ local newValue = TextYAlignment [newIndex ].Mode
355+ CustomTextLabel :UpdateVerticalAlignment (newValue )
356+ end )
357+
358+ xChoice :SetValueChangedFunction (function (newIndex )
359+ local newValue = TextXAlignment [newIndex ].Mode
360+ CustomTextLabel :UpdateHorizontalAlignment (newValue )
335361 end )
336362
337363 strokeCheckbox :SetValueChangedFunction (function (newValue )
338364 CustomTextLabel :UpdateStroke (newValue )
339365 end )
340366
341367 colorStrokeChoice :SetValueChangedFunction (function (newIndex )
342- local color = Color [newIndex ].Color
343- CustomTextLabel :UpdateStrokeColor (color )
368+ local newValue = Color [newIndex ].Color
369+ CustomTextLabel :UpdateStrokeColor (newValue )
344370 end )
345371
346372 joinStrokeChoice :SetValueChangedFunction (function (newIndex )
347- local join = LineJoinMode [newIndex ].Mode
348- CustomTextLabel :UpdateStrokeJoin (join )
373+ local newValue = LineJoinMode [newIndex ].Mode
374+ CustomTextLabel :UpdateStrokeJoin (newValue )
349375 end )
350376
351377 thicknessStrokeSlider :SetValueChangedFunction (function (newValue )
@@ -361,8 +387,8 @@ function PluginGui:newPluginGui(widgetGui)
361387 end )
362388
363389 colorBackgroundChoice :SetValueChangedFunction (function (newIndex )
364- local color = Color [newIndex ].Color
365- CustomTextLabel :UpdateBackgroundColor3 (color )
390+ local newValue = Color [newIndex ].Color
391+ CustomTextLabel :UpdateBackgroundColor3 (newValue )
366392 end )
367393end
368394
0 commit comments