Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
K
kicad-source-mirror
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Commits
Open sidebar
Elphel
kicad-source-mirror
Commits
52d35351
Commit
52d35351
authored
Dec 31, 2013
by
Dick Hollenbeck
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
minor tidying
parent
f9ab5d2c
Changes
2
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
91 additions
and
97 deletions
+91
-97
edaappl.cpp
common/edaappl.cpp
+78
-84
macros.h
include/macros.h
+13
-13
No files found.
common/edaappl.cpp
View file @
52d35351
This diff is collapsed.
Click to expand it.
include/macros.h
View file @
52d35351
...
@@ -34,22 +34,22 @@ static inline wxString FROM_UTF8( const char* cstring )
...
@@ -34,22 +34,22 @@ static inline wxString FROM_UTF8( const char* cstring )
/**
/**
* Function GetChars
* Function GetChars
* returns a wxChar* to the actual character data within a wxString, and is
* returns a wxChar* to the actual wxChar* data within a wxString, and is
* helpful for passing strings to wxString::Printf(wxT("%s"), GetChars(wxString) )
* helpful for passing strings to wxString::Printf() and wxString::Format().
* It can also be passed a UTF8 parameter which will be converted to wxString
* by the compiler.
* <p>
* <p>
* wxChar is defined to be
* Example: wxString::Format( wxT( "%s" ), GetChars( UTF( "some text" ) ) );
* <p>
* When wxWidgets is properly built for KiCad, a const wxChar* points to either:
* <ul>
* <ul>
* <li>
standard C style char when wxUSE_UNICODE==0
</li>
* <li>
32 bit unicode characters on linux/OSX or
</li>
* <li>
wchar_t when wxUSE_UNICODE==1 (the default)
. </li>
* <li>
16 bit UTF16 characters on windows
. </li>
* </ul>
* </ul>
* i.e. it depends on how the wxWidgets library was compiled.
* Note that you cannot pass 8 bit strings to wxString::Format() or Printf() so this
* ( wxUSE_UNICODE is defined in wxWidgets, inside setup.h.
* is a useful conversion function to wxChar*, which is needed by wxString::Format().
* for version >= 2.9 wxUSE_UNICODE is always defined to 1 )
*
* There was a period
* @return const wxChar* - a pointer to the UNICODE or UTF16 (on windows) text.
* during the development of wxWidgets 2.9 when GetData() was missing, so this
* function was used to provide insulation from that design change. It may
* no longer be needed, and is harmless. GetData() seems to be an acceptable
* alternative in all cases now.
*/
*/
static
inline
const
wxChar
*
GetChars
(
const
wxString
&
s
)
static
inline
const
wxChar
*
GetChars
(
const
wxString
&
s
)
{
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment