Skip to content
  • 0 Votes
    2 Posts
    634 Views
    Pl45m4P
    @HowardHarkness Hi there was a similar topic / question few years ago. @SGaist explained why there is one additional space after every mask -> to allow text selection by keyboard. Of course Ctrl + A kinda "hacks" it (to select all, at least) and if you dont need it, you could implement a workaround, but unfortunately there is no "Qt-way" to switch it off. https://forum.qt.io/topic/60633/qlineedit-using-input-mask-with-blank-space-replacement-cursor-select-replacement-char
  • QLineEdit with inputmask 9999;0

    Unsolved General and Desktop qlinedit inputmask
    4
    0 Votes
    4 Posts
    2k Views
    SGaistS
    You're welcome ! I'd also recommend using _ as placeholder char rather than 0, otherwise people will think there's a default PIN or maybe no protection at all.
  • 0 Votes
    15 Posts
    10k Views
    B
    Thanks for your answer, but this also would not work for other line edits. In QT creator I cannot find the input mask setting for the QSpinBox, this would be helpful in a shared project, so everyone directly would see the input Mask like in the QlinEdit. But anyway you solution would be a workaorund but does not explain why this issue . The only explanation like you already mentioned is because of useage of backspace deletion.