Subversion Repositories tpanel

Rev

Rev 71 | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 71 Rev 111
Line 1... Line 1...
1
/*
1
/*
2
 * Copyright (C) 2021 by Andreas Theofilu <andreas@theosys.at>
2
 * Copyright (C) 2021, 2022 by Andreas Theofilu <andreas@theosys.at>
3
 *
3
 *
4
 * This program is free software; you can redistribute it and/or modify
4
 * This program is free software; you can redistribute it and/or modify
5
 * it under the terms of the GNU General Public License as published by
5
 * it under the terms of the GNU General Public License as published by
6
 * the Free Software Foundation; either version 3 of the License, or
6
 * the Free Software Foundation; either version 3 of the License, or
7
 * (at your option) any later version.
7
 * (at your option) any later version.
Line 56... Line 56...
56
        ~TQKeypad();
56
        ~TQKeypad();
57
 
57
 
58
        void doResize();
58
        void doResize();
59
        void setPrivate(bool mode) { mPrivate = mode; }
59
        void setPrivate(bool mode) { mPrivate = mode; }
60
        void setScaleFactor(double sf) { mScaleFactor = sf; }
60
        void setScaleFactor(double sf) { mScaleFactor = sf; }
-
 
61
        void setMaxLength(int len) { mMaxLen = len; }
61
        std::string& getText() { return mText; }
62
        std::string& getText() { return mText; }
-
 
63
        void setString(const std::string& str);
62
 
64
 
63
    private slots:
65
    private slots:
64
        void key0() { setKey(Ui::KEYP_0); }
66
        void key0() { setKey(Ui::KEYP_0); }
65
        void key1() { setKey(Ui::KEYP_1); }
67
        void key1() { setKey(Ui::KEYP_1); }
66
        void key2() { setKey(Ui::KEYP_2); }
68
        void key2() { setKey(Ui::KEYP_2); }
Line 86... Line 88...
86
 
88
 
87
        bool mPrivate{false};       // TRUE = private mode. Only * is showed.
89
        bool mPrivate{false};       // TRUE = private mode. Only * is showed.
88
        double mScaleFactor{0.0};   // The scale factor if we are on a mobile device
90
        double mScaleFactor{0.0};   // The scale factor if we are on a mobile device
89
        std::string mText;          // The typed text.
91
        std::string mText;          // The typed text.
90
        std::string mSound;         // Path and name to a sound file played on every key press.
92
        std::string mSound;         // Path and name to a sound file played on every key press.
-
 
93
        int mMaxLen{0};             // If >0 then this is the maximum number of chars
91
};
94
};
92
 
95
 
93
#endif // TQKEYPAD_H
96
#endif // TQKEYPAD_H