Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

(WIP) Adding the ability to translate Maniplulator WB #11

Open
wants to merge 8 commits into
base: master
Choose a base branch
from

Conversation

luzpaz
Copy link
Contributor

@luzpaz luzpaz commented Sep 11, 2018

The commits in this branch are a WIP and any help is encouraged.

@luzpaz
Copy link
Contributor Author

luzpaz commented Sep 11, 2018

Bummer, still don't know how to use git well enough to avoid adding e09eccf which I already submit as #10 (No worries I'll actually rebase after #10 is merged).

8d8094b is lame because I artificially put it in a made up src/Tools/ dir so it would run, but it still doesn't run correctly. So it needs modifying. Perhaps you (@easyw) can help me with that? I've actually successfully got

pylupdate5 `find ./ -name "*.py"` -ts Resources/translations/Manipulator.ts`

to run and it pulls the translations from 6f6066a in to a new directory: Resources/translations. Unfortunately it also pulls translations from the oDraft.py file. So we need to figure out what to do with that one.

@easyw
Copy link
Owner

easyw commented Sep 11, 2018

@luzpaz
please find attached a previous translation done for an old version that a user sent me for French language.
copie_fichiers_traduits.zip

May those could be useful.
Maurice

@luzpaz luzpaz changed the title (WIP) Translating Maniplulator WB (WIP) Adding the ability to translate Maniplulator WB Sep 11, 2018
@luzpaz
Copy link
Contributor Author

luzpaz commented Sep 11, 2018

@easyw what do you want to do about oDraft.py what is it's future ? Are you going to fork it to work more seamlessly with Manipulator?

Starting to add QtCore.QT_TRANSLATE_NOOP(context, text) functions. Haven't tested yet.
I was trying to run it but was unsuccessful because it was copied from FC core and really needs to be fully adapted to run just for Manipulator.
@luzpaz
Copy link
Contributor Author

luzpaz commented Sep 26, 2018

@easyw 👆

+ needed a workaround to exclude oDraft.py (see easyw#12)
+ made some soft cosmetic adjustments to the script
@luzpaz
Copy link
Contributor Author

luzpaz commented Sep 26, 2018

When invoking the updatets.py script from root directory of ManipulatorWB i.e.
python src/Tools/updatets.py

I get the following:

[foo@foo FreeCAD-ManipulatorWB]$ python src/Tools/updatets.py 
QMake version 3.1
Using Qt version 5.11.1 in /usr/lib
lupdate version 5.11.1
lupdate version 4.8.7
sh: pylupdate: command not found
sh: pylupdate4: command not found
pylupdate5 v5.11.2
Qt tools: qmake lupdate-qt4 pylupdate5
Traceback (most recent call last):
  File "src/Tools/updatets.py", line 144, in <module>
    main()
  File "src/Tools/updatets.py", line 131, in main
    dirs=os.listdir("src/Mod")
FileNotFoundError: [Errno 2] No such file or directory: 'src/Mod'

So I realize that the updatets.py script needs a little more tweaking to work with Manipulator. src/Mod is what it's looking for because in the FreeCAD core those where all the different WBs are that need to be translated. In this repo, we need the script to search the root directory of the repo. Please advise

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants