Initial Vexta Core v0.1.0 release
This commit is contained in:
commit
25c454329d
2481 changed files with 689289 additions and 0 deletions
65
share/qt/Info.plist.in
Normal file
65
share/qt/Info.plist.in
Normal file
|
|
@ -0,0 +1,65 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE plist SYSTEM "file://localhost/System/Library/DTDs/PropertyList.dtd">
|
||||
<plist version="0.9">
|
||||
<dict>
|
||||
<key>LSMinimumSystemVersion</key>
|
||||
<string>10.14.0</string>
|
||||
|
||||
<key>LSArchitecturePriority</key>
|
||||
<array>
|
||||
<string>x86_64</string>
|
||||
</array>
|
||||
|
||||
<key>CFBundleIconFile</key>
|
||||
<string>vexta.icns</string>
|
||||
|
||||
<key>CFBundlePackageType</key>
|
||||
<string>APPL</string>
|
||||
|
||||
<key>NSHumanReadableCopyright</key>
|
||||
<string>@CLIENT_VERSION_MAJOR@.@CLIENT_VERSION_MINOR@.@CLIENT_VERSION_BUILD@, Copyright © 2009-@COPYRIGHT_YEAR@ @COPYRIGHT_HOLDERS_FINAL@</string>
|
||||
|
||||
<key>CFBundleShortVersionString</key>
|
||||
<string>@CLIENT_VERSION_MAJOR@.@CLIENT_VERSION_MINOR@.@CLIENT_VERSION_BUILD@</string>
|
||||
|
||||
<key>CFBundleVersion</key>
|
||||
<string>@CLIENT_VERSION_MAJOR@.@CLIENT_VERSION_MINOR@.@CLIENT_VERSION_BUILD@</string>
|
||||
|
||||
<key>CFBundleSignature</key>
|
||||
<string>????</string>
|
||||
|
||||
<key>CFBundleExecutable</key>
|
||||
<string>Vexta-Qt</string>
|
||||
<key>CFBundleName</key>
|
||||
<string>Vexta-Qt</string>
|
||||
|
||||
<key>LSHasLocalizedDisplayName</key>
|
||||
<true/>
|
||||
|
||||
<key>CFBundleIdentifier</key>
|
||||
<string>org.vexta.Vexta-Qt</string>
|
||||
|
||||
<key>CFBundleURLTypes</key>
|
||||
<array>
|
||||
<dict>
|
||||
<key>CFBundleTypeRole</key>
|
||||
<string>Editor</string>
|
||||
<key>CFBundleURLName</key>
|
||||
<string>org.vexta.VextaPayment</string>
|
||||
<key>CFBundleURLSchemes</key>
|
||||
<array>
|
||||
<string>digibyte</string>
|
||||
</array>
|
||||
</dict>
|
||||
</array>
|
||||
|
||||
<key>NSPrincipalClass</key>
|
||||
<string>NSApplication</string>
|
||||
|
||||
<key>NSHighResolutionCapable</key>
|
||||
<string>True</string>
|
||||
|
||||
<key>LSApplicationCategoryType</key>
|
||||
<string>public.app-category.finance</string>
|
||||
</dict>
|
||||
</plist>
|
||||
86
share/qt/extract_strings_qt.py
Executable file
86
share/qt/extract_strings_qt.py
Executable file
|
|
@ -0,0 +1,86 @@
|
|||
#!/usr/bin/env python3
|
||||
# Copyright (c) 2012-2018 The Bitcoin Core developers
|
||||
# Copyright (c) 2012-2019 The DigiByte Core developers
|
||||
# Distributed under the MIT software license, see the accompanying
|
||||
# file COPYING or http://www.opensource.org/licenses/mit-license.php.
|
||||
'''
|
||||
Extract _("...") strings for translation and convert to Qt stringdefs so that
|
||||
they can be picked up by Qt linguist.
|
||||
'''
|
||||
from subprocess import Popen, PIPE
|
||||
import operator
|
||||
import os
|
||||
import sys
|
||||
|
||||
OUT_CPP="qt/digibytestrings.cpp"
|
||||
EMPTY=['""']
|
||||
|
||||
def parse_po(text):
|
||||
"""
|
||||
Parse 'po' format produced by xgettext.
|
||||
Return a list of (msgid,msgstr) tuples.
|
||||
"""
|
||||
messages = []
|
||||
msgid = []
|
||||
msgstr = []
|
||||
in_msgid = False
|
||||
in_msgstr = False
|
||||
|
||||
for line in text.split('\n'):
|
||||
line = line.rstrip('\r')
|
||||
if line.startswith('msgid '):
|
||||
if in_msgstr:
|
||||
messages.append((msgid, msgstr))
|
||||
in_msgstr = False
|
||||
# message start
|
||||
in_msgid = True
|
||||
|
||||
msgid = [line[6:]]
|
||||
elif line.startswith('msgstr '):
|
||||
in_msgid = False
|
||||
in_msgstr = True
|
||||
msgstr = [line[7:]]
|
||||
elif line.startswith('"'):
|
||||
if in_msgid:
|
||||
msgid.append(line)
|
||||
if in_msgstr:
|
||||
msgstr.append(line)
|
||||
|
||||
if in_msgstr:
|
||||
messages.append((msgid, msgstr))
|
||||
|
||||
return messages
|
||||
|
||||
files = sys.argv[1:]
|
||||
|
||||
# xgettext -n --keyword=_ $FILES
|
||||
XGETTEXT=os.getenv('XGETTEXT', 'xgettext')
|
||||
if not XGETTEXT:
|
||||
print('Cannot extract strings: xgettext utility is not installed or not configured.',file=sys.stderr)
|
||||
print('Please install package "gettext" and re-run \'./configure\'.',file=sys.stderr)
|
||||
sys.exit(1)
|
||||
child = Popen([XGETTEXT,'--output=-','--from-code=utf-8','-n','--keyword=_'] + files, stdout=PIPE)
|
||||
(out, err) = child.communicate()
|
||||
|
||||
messages = parse_po(out.decode('utf-8'))
|
||||
|
||||
f = open(OUT_CPP, 'w', encoding="utf8")
|
||||
f.write("""
|
||||
|
||||
#include <QtGlobal>
|
||||
|
||||
// Automatically generated by extract_strings_qt.py
|
||||
#ifdef __GNUC__
|
||||
#define UNUSED __attribute__((unused))
|
||||
#else
|
||||
#define UNUSED
|
||||
#endif
|
||||
""")
|
||||
f.write('static const char UNUSED *digibyte_strings[] = {\n')
|
||||
f.write('QT_TRANSLATE_NOOP("digibyte-core", "%s"),\n' % (os.getenv('COPYRIGHT_HOLDERS'),))
|
||||
messages.sort(key=operator.itemgetter(0))
|
||||
for (msgid, msgstr) in messages:
|
||||
if msgid != EMPTY:
|
||||
f.write('QT_TRANSLATE_NOOP("digibyte-core", %s),\n' % ('\n'.join(msgid)))
|
||||
f.write('};\n')
|
||||
f.close()
|
||||
Loading…
Reference in a new issue