FaceMakerCheese is adapted face-making code of Part Extrude and PartDesign (same code was repeated in about three places I think). I called it "cheese" because it supports making faces with holes, but doesn't support islands inside holes. If you take a slice of cheese, it can have holes but can't have islands inside holes... That's why!
Thanks, creative, but not working for me. C++ may not be directly recognizing html, seems like Python does?
Thanks, I'm very much tempted to change it to utf8. I'm guessing it shouldn't affect other errors that use this routine.
I'd like to try, if I can figure out the PR process with Git (so far I've only created a local branch - maybe I'll make things easier on myself and redo everything on Github's web UI!). I had already made the same change in FeatureHole.cpp, I hadn't thought of looking in FeatureGroove.cpp.
Ha! Thanks for the explanation, the Swiss cheese analogy did pass through my mind.
Not at all because Qt's lupdate tool won't pick up the string because it's not marked accordingly. The string must be put inside the QT_TR_NOOP macro and then when it is about to be displayed QApplication::translate must be used.Now, the big question is, how will this text string be translated?
I guess that it will show the \xe2\x80\xa2. However, it's always a bit problematic if technical stuff is part of a string because some translators don't know what to do and simply omit it.I mean, how will it appear on Crowdin: as it's shown above, or will the bullet points be shown as \xe2\x80\xa2
Code: Select all
/* TRANSLATOR PartDesign::Pocket */
Code: Select all
std::string message = QT_TR_NOOP("The requested feature cannot be created. The reason may be that:");
message += "\n\xe2\x80\xa2";
message += QT_TR_NOOP("the active Body does not contain a base shape, so there is no material to be removed");
message += "\n\xe2\x80\xa2";
message += QT_TR_NOOP("the selected sketch does not belong to the active Body.");
Code: Select all
QMessageBox::warning(Gui::getMainWindow(), tr("Input error"), QApplication::translate(feature->getTypeId().getName(), e.what()));
But will it work at all? I thought, Qt looks up the whole string in the translation library, but will not find it because only pieces are in the library?wmayer wrote: ↑Tue Dec 04, 2018 9:06 am...Code: Select all
std::string message = QT_TR_NOOP("The requested feature cannot be created. The reason may be that:"); message += "\n\xe2\x80\xa2"; message += QT_TR_NOOP("the active Body does not contain a base shape, so there is no material to be removed"); message += "\n\xe2\x80\xa2"; message += QT_TR_NOOP("the selected sketch does not belong to the active Body.");
The code to display the error message should then be changed to (TaskDlgFeatureParameters::accept()):Code: Select all
QMessageBox::warning(..., QApplication::translate(..., e.what()));