Fill in version in a sketch validator message

Post here if you have re-based and finalised code to integrate into master, which was discussed, agreed to and tested in other forums. You can also submit your PR directly on github.
Post Reply
User avatar
DeepSOIC
Posts: 7167
Joined: Fri Aug 29, 2014 12:45 am
Location: Saint-Petersburg, Russia

Fill in version in a sketch validator message

Post by DeepSOIC » Sat Feb 28, 2015 4:11 pm

Please cherry-pick this commit:
git commit eabc25d70f00907ab5e67456e5efed136283da8d

The commit is:
I've put question marks in FreeCAD version contained in a message, that was to be put in after the code is merged. I'm filling it in.

I've done it in a way that the actual message is not changed, to not affect translations.

PS. I wonder, why github says "Sorry, diff information is unavailable." That's why I've attached a screenshot.
Attachments
commit eabc25d70f00907ab5e67456e5efed136283da8d.png
commit eabc25d70f00907ab5e67456e5efed136283da8d.png (132.3 KiB) Viewed 2011 times

User avatar
shoogen
Posts: 2823
Joined: Thu Dec 01, 2011 5:24 pm

Re: Fill in version in a sketch validator message

Post by shoogen » Sat Feb 28, 2015 4:27 pm

DeepSOIC wrote:I've done it in a way that the actual message is not changed, to not affect translations.
The 0.15 is translated and the 4585 is not translated? Sounds not very useful to me. If the string will never change again, it can be included in the translation. In the long run i want to search for (exact) error messages in the source code (and ts-files).

wmayer
Site Admin
Posts: 15000
Joined: Thu Feb 19, 2009 10:32 am

Re: Fill in version in a sketch validator message

Post by wmayer » Sat Feb 28, 2015 4:43 pm

Also the "???" could be problematic. For the translator it's not obvious that the translated string must also have three question marks. In case he uses only one or two the message will be broken at runtime. You better have did it like this:

Code: Select all

"... in FreeCAD older than %3").arg(...).arg(...).arg(QString::fromLatin1(v0.15.4585))

User avatar
shoogen
Posts: 2823
Joined: Thu Dec 01, 2011 5:24 pm

Re: Fill in version in a sketch validator message

Post by shoogen » Sat Feb 28, 2015 5:03 pm

DeepSOIC wrote:PS. I wonder, why github says "Sorry, diff information is unavailable."
https://github.com/FreeCAD/FreeCAD_sf_m ... -squashed2
Maybe because the branch is not properly rebased?

User avatar
DeepSOIC
Posts: 7167
Joined: Fri Aug 29, 2014 12:45 am
Location: Saint-Petersburg, Russia

Re: Fill in version in a sketch validator message

Post by DeepSOIC » Sat Feb 28, 2015 5:20 pm

Then just type the version directly into the message.

User avatar
DeepSOIC
Posts: 7167
Joined: Fri Aug 29, 2014 12:45 am
Location: Saint-Petersburg, Russia

Re: Fill in version in a sketch validator message

Post by DeepSOIC » Sat Feb 28, 2015 5:40 pm

shoogen wrote:
DeepSOIC wrote:PS. I wonder, why github says "Sorry, diff information is unavailable."
https://github.com/FreeCAD/FreeCAD_sf_m ... -squashed2
Maybe because the branch is not properly rebased?
I don't think so, since it doesn't stop other commits from being displayed. The branch is not rebased at all :oops: , I've just done this small change on top of the branch as it was for my previous pull request.

Post Reply