Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
converse.js
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
converse.js
Commits
35a8112c
Commit
35a8112c
authored
Apr 20, 2015
by
Gernot Pansy
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
allow adding language on resx and osx strings (utf-8 only) file formats
parent
d9e24ab8
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
30 additions
and
0 deletions
+30
-0
weblate/trans/formats.py
weblate/trans/formats.py
+30
-0
No files found.
weblate/trans/formats.py
View file @
35a8112c
...
...
@@ -814,6 +814,21 @@ class StringsUtf8Format(FileFormat):
format_id
=
'strings-utf8'
loader
=
(
'properties'
,
'stringsutf8file'
)
@
classmethod
def
supports_new_language
(
cls
):
'''
Checks whether we can create new language file.
'''
return
True
@
staticmethod
def
add_language
(
filename
,
code
,
base
):
'''
Adds new language file.
'''
with
open
(
filename
,
'w'
)
as
output
:
output
.
write
(
'
\
n
'
)
@
register_fileformat
class
PropertiesUtf8Format
(
FileFormat
):
...
...
@@ -869,6 +884,21 @@ class RESXFormat(FileFormat):
monolingual
=
True
unit_class
=
RESXUnit
@
classmethod
def
supports_new_language
(
cls
):
'''
Checks whether we can create new language file.
'''
return
True
@
staticmethod
def
add_language
(
filename
,
code
,
base
):
'''
Adds new language file.
'''
with
open
(
filename
,
'w'
)
as
output
:
output
.
write
(
'''<?xml version='1.0' encoding='utf-8'?>
<root></root>'''
)
@
register_fileformat
class
AndroidFormat
(
FileFormat
):
...
...
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