]> git.lyx.org Git - lyx.git/blob - src/frontends/xforms/forms_gettext.C
scex and idex now receive and return string, not char *.
[lyx.git] / src / frontends / xforms / forms_gettext.C
1 /**
2  * \file forms_gettext.C
3  * This file is part of LyX, the document processor.
4  * Licence details can be found in the file COPYING.
5  *
6  * \author Angus Leeming
7  *
8  * Full author contact details are available in file CREDITS
9  */
10 #include <config.h>
11
12 #ifdef __GNUG__
13 #pragma implementation
14 #endif
15
16 #include "forms_gettext.h"
17 #include "support/lstrings.h"
18
19 // Extract shortcut from "<identifier>|<shortcut>" string
20 string const scex(string const & str)
21 {
22         return split(str, '|');
23 }
24
25
26 // Extract identifier from "<identifier>|<shortcut>" string
27 string const idex(string const & str)
28 {
29         string identifier;
30         split(str, identifier, '|');
31         return identifier;
32 }