public static Label NewLabelFormattedString(FormattedString formattedText, string fontSize = VariablesGlobal.TEXT_SIZE_MEDIUM) { Label label = new Label { FormattedText = formattedText }; label.FontSize = FontSizes.DeviceNamedFontSize(fontSize, label); return(label); }
public static Label NewLabelString(string text = "", string fontSize = VariablesGlobal.TEXT_SIZE_MEDIUM) { Label label = new Label { Text = text }; label.FontSize = FontSizes.DeviceNamedFontSize(fontSize, label); return(label); }
public static Entry NewEntry(string text = "", string fontSize = VariablesGlobal.TEXT_SIZE_MEDIUM) { Entry entry = new Entry { Text = text, }; entry.FontSize = FontSizes.DeviceNamedFontSize(fontSize, entry); return(entry); }
public static Editor NewEditor(string text = "", string fontSize = VariablesGlobal.TEXT_SIZE_MEDIUM, double margin = 0) { Editor editor = new Editor { Text = text, Margin = margin, }; editor.FontSize = FontSizes.DeviceNamedFontSize(fontSize, editor); return(editor); }
public static Span NewSpan(string text = "", string fontSize = VariablesGlobal.TEXT_SIZE_MEDIUM, FontAttributes fontAttributes = FontAttributes.None, string foregroundColour = "") { Span span = new Span { Text = text, FontAttributes = fontAttributes, }; span.ForegroundColor = Validation.ValidateHexCode(foregroundColour); span.FontSize = FontSizes.DeviceNamedFontSize(fontSize, span); return(span); }