modified wxLANGUAGE generating script to visibly mark automatically generated code
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@9577 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
parent
1159a76f9c
commit
323af1967c
@ -20,6 +20,9 @@ def ReadTable():
|
||||
def GenEnum(table):
|
||||
f = open('_wxlang.h', 'wt')
|
||||
f.write("""
|
||||
|
||||
// --- --- --- generated code begins here --- --- ---
|
||||
|
||||
// This enum is generated by misc/languages/genlang.py
|
||||
// When making changes, please put them into misc/languages/langtabl.txt
|
||||
enum wxLanguage
|
||||
@ -36,6 +39,9 @@ enum wxLanguage
|
||||
// for custom, user-defined languages:
|
||||
wxLANGUAGE_USER_DEFINED
|
||||
};
|
||||
|
||||
// --- --- --- generated code ends here --- --- ---
|
||||
|
||||
""")
|
||||
f.close()
|
||||
|
||||
@ -43,6 +49,9 @@ enum wxLanguage
|
||||
def GenDocs(table):
|
||||
f = open('_wxlang.tex', 'wt')
|
||||
f.write("""
|
||||
|
||||
%% --- --- --- generated code begins here --- --- ---
|
||||
|
||||
%% This enum is generated by misc/languages/genlang.py
|
||||
%% When making changes, please put them into misc/languages/langtabl.txt
|
||||
\\begin{itemize}\\itemsep=0pt
|
||||
@ -55,6 +64,9 @@ this
|
||||
for i in table:
|
||||
f.write('\\item %s\n' % (i[0].replace('_','\\_')))
|
||||
f.write("""\\end{itemize}
|
||||
|
||||
%% --- --- --- generated code ends here --- --- ---
|
||||
|
||||
""")
|
||||
f.close()
|
||||
|
||||
@ -89,6 +101,8 @@ def GenTable(table):
|
||||
|
||||
f = open('_wxlang.cpp', 'wt')
|
||||
f.write("""
|
||||
// --- --- --- generated code begins here --- --- ---
|
||||
|
||||
// This table is generated by misc/languages/genlang.py
|
||||
// When making changes, please put them into misc/languages/langtabl.txt
|
||||
|
||||
@ -120,6 +134,9 @@ void wxLocale::InitLanguagesDB()
|
||||
%s
|
||||
};
|
||||
#undef LNG
|
||||
|
||||
// --- --- --- generated code ends here --- --- ---
|
||||
|
||||
""" % (ifdefs, lngtable))
|
||||
f.close()
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user