1
/****************************************************************************
3
** This file is part of the LibreCAD project, a 2D CAD program
5
** Copyright (C) 2011 R. van Twisk (librecad@rvt.dds.nl)
8
** This file may be distributed and/or modified under the terms of the
9
** GNU General Public License version 2 as published by the Free Software
10
** Foundation and appearing in the file gpl-2.0.txt included in the
11
** packaging of this file.
13
** This program is distributed in the hope that it will be useful,
14
** but WITHOUT ANY WARRANTY; without even the implied warranty of
15
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16
** GNU General Public License for more details.
18
** You should have received a copy of the GNU General Public License
19
** along with this program; if not, write to the Free Software
20
** Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
22
** This copyright notice MUST APPEAR in all copies of the script!
24
**********************************************************************/
33
* Store Locale information in a class
34
* (c) 2011 R. van Twisk
37
class RS_Locale :public QLocale {
40
RS_Locale(const QString &_canonical);
41
/* without virtual destructor => warning: deleting object of polymorphic
42
* class type 'RS_Locale' which has non-virtual destructor might cause
43
* undefined behaviour [-Wdelete-non-virtual-dtor]
45
* TNick <nicu.tofan@gmail.com>
47
virtual ~RS_Locale(){}
50
virtual void setCanonical(const QString &_canonical);
51
virtual void setDirection(RS2::TextLocaleDirection direction);
52
virtual void setName(const QString &_name);
53
virtual QString name() const;
54
static QString toCanonical(const QString &canonical);
56
QString getCanonical();