Base::Tools Struct Reference

#include <Tools.h>

Static Public Member Functions

static std::string addNumber (const std::string &, unsigned int, int d=0)
 
static std::string escapedUnicodeFromUtf8 (const char *s)
 
static std::string escapedUnicodeToUtf8 (const std::string &s)
 
static QString escapeEncodeFilename (const QString &s)
 
static std::string escapeEncodeFilename (const std::string &s)
 
static QString escapeEncodeString (const QString &s)
 
static std::string escapeEncodeString (const std::string &s)
 
static QString fromStdString (const std::string &s)
 fromStdString Convert a std::string encoded as UTF-8 into a QString. More...
 
static std::string getIdentifier (const std::string &)
 
static std::string getUniqueName (const std::string &, const std::vector< std::string > &, int d=0)
 
static std::string narrow (const std::wstring &str)
 
static std::string toStdString (const QString &s)
 toStdString Convert a QString into a UTF-8 encoded std::string. More...
 
static std::wstring widen (const std::string &str)
 

Member Function Documentation

◆ addNumber()

std::string Base::Tools::addNumber ( const std::string &  name,
unsigned int  num,
int  d = 0 
)
static

◆ escapedUnicodeFromUtf8()

◆ escapedUnicodeToUtf8()

std::string Base::Tools::escapedUnicodeToUtf8 ( const std::string &  s)
static

◆ escapeEncodeFilename() [1/2]

◆ escapeEncodeFilename() [2/2]

std::string Base::Tools::escapeEncodeFilename ( const std::string &  s)
static

◆ escapeEncodeString() [1/2]

◆ escapeEncodeString() [2/2]

std::string Base::Tools::escapeEncodeString ( const std::string &  s)
static

◆ fromStdString()

static QString Base::Tools::fromStdString ( const std::string &  s)
static

fromStdString Convert a std::string encoded as UTF-8 into a QString.

Parameters
sstd::string, expected to be UTF-8 encoded.
Returns
String represented as a QString.

Referenced by StdCmdDelete::activated(), SpreadsheetGui::SheetModel::data(), ConstraintItem::data(), Gui::Dialog::DlgExpressionInput::DlgExpressionInput(), TechDrawGui::QGIWeldSymbol::drawTailText(), Gui::QuantitySpinBox::event(), SketcherGui::EditDatumDialog::exec(), TechDraw::DrawSVGTemplate::execute(), TechDrawGui::TaskSectionView::failNoObject(), TechDraw::DrawViewDimension::getDefaultFormatSpec(), MRichTextEdit::getDefFont(), Spreadsheet::Cell::getFormattedQuantity(), TechDrawGui::TaskLineDecor::initUi(), TechDrawGui::DlgPrefsTechDrawDimensionsImp::loadSettings(), SpreadsheetGui::PropertiesDialog::PropertiesDialog(), Gui::ExpLineEdit::resizeEvent(), TechDrawGui::QGITile::setFont(), TechDrawGui::TaskHatch::setUiEdit(), TechDrawGui::TaskSectionView::setUiEdit(), TechDrawGui::TaskCenterLine::setUiEdit(), TechDrawGui::TaskCustomizeFormat::setUiEdit(), TechDrawGui::TaskLeaderLine::setUiEdit(), TechDrawGui::TaskRichAnno::setUiEdit(), TechDrawGui::TaskDetail::setUiFromFeat(), TechDrawGui::TaskHatch::setUiPrimary(), TechDrawGui::TaskSectionView::setUiPrimary(), TechDrawGui::TaskCenterLine::setUiPrimary(), TechDrawGui::TaskCosVertex::setUiPrimary(), TechDrawGui::TaskLeaderLine::setUiPrimary(), TechDrawGui::TaskRichAnno::setUiPrimary(), SpreadsheetGui::SheetModel::SheetModel(), Gui::ExpressionSpinBox::showValidExpression(), Gui::ExpressionCompleter::slotUpdate(), and FemGui::TaskFemConstraintFluidBoundary::TaskFemConstraintFluidBoundary().

◆ getIdentifier()

◆ getUniqueName()

◆ narrow()

std::string Base::Tools::narrow ( const std::wstring &  str)
static

◆ toStdString()

◆ widen()

std::wstring Base::Tools::widen ( const std::string &  str)
static

The documentation for this struct was generated from the following files: