diff options
Diffstat (limited to 'doc')
-rw-r--r-- | doc/README.qt | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/doc/README.qt b/doc/README.qt index f914034e38..1d530f452d 100644 --- a/doc/README.qt +++ b/doc/README.qt @@ -179,7 +179,16 @@ code uses InterCapConvention for class names and methods and underscore_convention for variables, with a trailing underscore for member variables. -2.1.2 Mixing C and C++ +2.1.2 Strings + +If you're using GLib string functions or plain old C character array idioms in +Qt-only code you're probably doing something wrong. QStrings are generally +*much* safer and easier to use. They also make translations eaiser. + +If you need to pass strings between Qt and GLib you can use qstring_strdup +gchar_free_to_qstring, which are defined in ui/qt/qt_ui_utils.h. + +2.1.3 Mixing C and C++ Sometimes we have to call C++ functions from one of Wireshark's C callbacks and pass C++ objects to or from C. The C++ FAQ describes how to do this safely: @@ -216,4 +225,3 @@ Qt makes translating the Wireshark UI into different languages easy. More information about Qt Linguist http://qt-project.org/doc/qt-4.8/linguist-manual.html - |