HeaderPane
Main
Hide
Share Link
Print

PromptUnderline Property, SftMask Class

Defines whether input positions are underlined while the control has the input focus.

Class: SftMask
Namespace: Softelvdm.SftMaskNET
Assembly: Softelvdm.SftMaskNET

Syntax

public bool PromptUnderline { get; set; }
Public Property PromptUnderline As Boolean

Value

True to underline the input positions, False otherwise.

The default value is True.

Comments

Defines whether input positions are underlined while the control has the input focus.

Literals are not underlined. Without a mask, all characters are underlined.

Examples

C# View entire sample code

                comboCulture.Items.Add(CultureInfo.GetCultureInfo(name));
            comboCulture.SelectedItem = CultureInfo.GetCultureInfo("en-US");
            FillCombo(comboDarkMode, typeof(DarkModeEnum), sftMaskPhone.DarkMode);
            FillCombo(comboHighContrast, typeof(HighContrastModeEnum), sftMaskPhone.HighContrastMode);
            FillCombo(comboInputMode, typeof(InputModeEnum), sftMaskPhone.InputMode);
            FillCombo(comboEntrySelect, typeof(EntrySelectEnum), sftMaskPhone.EntrySelect);
            comboPrompt.Items.AddRange(new object[] { "(space)", "_", "#", "*" });
            comboPrompt.SelectedIndex = 1;
            checkUnderline.Checked = sftMaskPhone.PromptUnderline;
            ShowColor();
            DpiChanged += Form1_DpiChanged;
        }

        // On the .NET Framework, a ComboBox in a container keeps its old font when the window moves to a monitor with
        // another scale. Setting another font and then the inherited one again makes it use the new one.
        private void Form1_DpiChanged(object sender, DpiChangedEventArgs e) {

VB.NET View entire sample code

        Next
        ComboCulture.SelectedItem = CultureInfo.GetCultureInfo("en-US")
        FillCombo(ComboDarkMode, GetType(DarkModeEnum), SftMaskPhone.DarkMode)
        FillCombo(ComboHighContrast, GetType(HighContrastModeEnum), SftMaskPhone.HighContrastMode)
        FillCombo(ComboInputMode, GetType(InputModeEnum), SftMaskPhone.InputMode)
        FillCombo(ComboEntrySelect, GetType(EntrySelectEnum), SftMaskPhone.EntrySelect)
        ComboPrompt.Items.AddRange(New Object() {"(space)", "_", "#", "*"})
        ComboPrompt.SelectedIndex = 1
        CheckUnderline.Checked = SftMaskPhone.PromptUnderline
        ShowColor()
    End Sub

    ' On the .NET Framework, a ComboBox in a container keeps its old font when the window moves to a monitor with
    ' another scale. Setting another font and then the inherited one again makes it use the new one.
    Private Sub Form1_DpiChanged(ByVal sender As Object, ByVal e As DpiChangedEventArgs) Handles Me.DpiChanged
        BeginInvoke(New MethodInvoker(Sub()

See Also SftMask Class | Classes | SftMask/NET 3.0