#include <map>
#include <string>
#include <string.h>
#include "ut_types.h"
#include <fribidi.h>
Go to the source code of this file.
Defines | |
#define | UT_UCS4_isalnum(x) (UT_UCS4_isalpha(x) || UT_UCS4_isdigit(x)) |
#define | UT_UCS4_ispunct(x) ((!UT_UCS4_isspace(x) && !UT_UCS4_isalnum(x) && (x)>' ')) |
#define | UT_strptime strptime |
#define | UT_BIDI_LTR FRIBIDI_TYPE_LTR |
#define | UT_BIDI_RTL FRIBIDI_TYPE_RTL |
#define | UT_BIDI_WS FRIBIDI_TYPE_WS |
#define | UT_BIDI_EN FRIBIDI_TYPE_EN |
#define | UT_BIDI_ES FRIBIDI_TYPE_ES |
#define | UT_BIDI_ET FRIBIDI_TYPE_ET |
#define | UT_BIDI_AN FRIBIDI_TYPE_AN |
#define | UT_BIDI_CS FRIBIDI_TYPE_CS |
#define | UT_BIDI_BS FRIBIDI_TYPE_BS |
#define | UT_BIDI_SS FRIBIDI_TYPE_SS |
#define | UT_BIDI_AL FRIBIDI_TYPE_AL |
#define | UT_BIDI_NSM FRIBIDI_TYPE_NSM |
#define | UT_BIDI_RLE FRIBIDI_TYPE_RLE |
#define | UT_BIDI_LRE FRIBIDI_TYPE_LRE |
#define | UT_BIDI_LRO FRIBIDI_TYPE_LRO |
#define | UT_BIDI_RLO FRIBIDI_TYPE_RLO |
#define | UT_BIDI_PDF FRIBIDI_TYPE_PDF |
#define | UT_BIDI_ON FRIBIDI_TYPE_ON |
#define | UT_BIDI_UNSET FRIBIDI_TYPE_UNSET |
#define | UT_BIDI_IGNORE FRIBIDI_TYPE_IGNORE |
#define | UT_BIDI_IS_STRONG FRIBIDI_IS_STRONG |
#define | UT_BIDI_IS_WEAK FRIBIDI_IS_WEAK |
#define | UT_BIDI_IS_NUMBER FRIBIDI_IS_NUMBER |
#define | UT_BIDI_IS_RTL FRIBIDI_IS_RTL |
#define | UT_BIDI_IS_NEUTRAL FRIBIDI_IS_NEUTRAL |
#define | UT_BIDI_IS_LETTER FRIBIDI_IS_LETTER |
#define | UT_BIDI_IS_NSM(x) ((x) & FRIBIDI_MASK_NSM) |
Typedefs | |
typedef FriBidiCharType | UT_BidiCharType |
Functions | |
G_BEGIN_DECLS ABI_EXPORT bool | UT_XML_cloneNoAmpersands (gchar *&rszDest, const gchar *szSource) |
ABI_EXPORT bool | UT_XML_cloneConvAmpersands (gchar *&rszDest, const gchar *szSource) |
ABI_EXPORT const gchar * | UT_XML_transNoAmpersands (const gchar *szSource) |
ABI_EXPORT void | UT_decodeUTF8string (const gchar *p, UT_uint32 len, UT_GrowBuf *pResult) |
ABI_EXPORT bool | UT_ensureValidXML (std::string &s) |
Ensure a key or property is valid XML. | |
ABI_EXPORT bool | UT_isValidXML (const char *s) |
ABI_EXPORT bool | UT_validXML (char *s) |
ABI_EXPORT bool | UT_isSmartQuotableCharacter (UT_UCSChar c) |
ABI_EXPORT bool | UT_isSmartQuotedCharacter (UT_UCSChar c) |
ABI_EXPORT UT_uint32 | UT_UCS2_strlen (const UT_UCS2Char *string) |
ABI_EXPORT bool | UT_UCS4_isupper (UT_UCS4Char c) |
ABI_EXPORT bool | UT_UCS4_islower (UT_UCS4Char c) |
ABI_EXPORT bool | UT_UCS4_isalpha (UT_UCS4Char c) |
ABI_EXPORT bool | UT_UCS4_isSentenceSeparator (UT_UCS4Char c) |
ABI_EXPORT bool | UT_UCS4_isdigit (UT_UCS4Char c) |
ABI_EXPORT bool | UT_UCS4_isspace (UT_UCS4Char c) |
ABI_EXPORT UT_sint32 | UT_UCS4_strcmp (const UT_UCS4Char *left, const UT_UCS4Char *right) |
ABI_EXPORT UT_UCS4Char * | UT_UCS4_strstr (const UT_UCS4Char *phaystack, const UT_UCS4Char *pneedle) |
ABI_EXPORT UT_UCS4Char * | UT_UCS4_stristr (const UT_UCS4Char *phaystack, const UT_UCS4Char *pneedle) |
ABI_EXPORT UT_uint32 | UT_UCS4_strlen (const UT_UCS4Char *string) |
ABI_EXPORT UT_uint32 | UT_UCS4_strlen_as_char (const UT_UCS4Char *string) |
ABI_EXPORT UT_UCS4Char * | UT_UCS4_strcpy (UT_UCS4Char *dest, const UT_UCS4Char *src) |
ABI_EXPORT UT_UCS4Char * | UT_UCS4_strcpy_char (UT_UCS4Char *dest, const char *src) |
ABI_EXPORT UT_UCS4Char * | UT_UCS4_strncpy_char (UT_UCS4Char *dest, const char *src, int) |
ABI_EXPORT UT_UCS4Char * | UT_UCS4_strcpy_utf8_char (UT_UCS4Char *dest, const char *src) |
ABI_EXPORT char * | UT_UCS4_strcpy_to_char (char *dest, const UT_UCS4Char *src) |
ABI_EXPORT char * | UT_UCS4_strncpy_to_char (char *dest, const UT_UCS4Char *src, int) |
ABI_EXPORT bool | UT_UCS4_cloneString (UT_UCS4Char **dest, const UT_UCS4Char *src) |
ABI_EXPORT bool | UT_UCS4_cloneString_char (UT_UCS4Char **dest, const char *src) |
ABI_EXPORT UT_UCS4Char * | UT_UCS4_strncpy (UT_UCS4Char *dest, const UT_UCS4Char *src, UT_uint32 n) |
ABI_EXPORT UT_UCS4Char * | UT_UCS4_strnrev (UT_UCS4Char *dest, UT_uint32 n) |
ABI_EXPORT UT_UCS4Char | UT_UCS4_tolower (UT_UCS4Char c) |
ABI_EXPORT UT_UCS4Char | UT_UCS4_toupper (UT_UCS4Char c) |
Convert a given character to uppercase. | |
ABI_EXPORT void | UT_parse_attributes (const char *attributes, std::map< std::string, std::string > &map) |
ABI_EXPORT void | UT_parse_properties (const char *props, std::map< std::string, std::string > &map) |
ABI_EXPORT const char * | std_size_string (float f) |
ABI_EXPORT UT_BidiCharType | UT_bidiGetCharType (UT_UCS4Char c) |
ABI_EXPORT bool | UT_bidiMapLog2Vis (const UT_UCS4Char *pStrIn, UT_uint32 len, UT_BidiCharType baseDir, UT_uint32 *pL2V, UT_uint32 *pV2L, UT_Byte *pEmbed) |
ABI_EXPORT bool | UT_bidiReorderString (const UT_UCS4Char *pStrIn, UT_uint32 len, UT_BidiCharType baseDir, UT_UCS4Char *pStrOut) |
ABI_EXPORT bool | UT_bidiGetMirrorChar (UT_UCS4Char c, UT_UCS4Char &mc) |
#define UT_BIDI_AL FRIBIDI_TYPE_AL |
Referenced by fp_Line::_createMapOfRuns().
#define UT_BIDI_AN FRIBIDI_TYPE_AN |
Referenced by fp_Line::_createMapOfRuns().
#define UT_BIDI_BS FRIBIDI_TYPE_BS |
Referenced by fp_Line::_createMapOfRuns().
#define UT_BIDI_CS FRIBIDI_TYPE_CS |
Referenced by fp_Line::_createMapOfRuns().
#define UT_BIDI_EN FRIBIDI_TYPE_EN |
Referenced by fp_Line::_createMapOfRuns().
#define UT_BIDI_ES FRIBIDI_TYPE_ES |
Referenced by fp_Line::_createMapOfRuns().
#define UT_BIDI_ET FRIBIDI_TYPE_ET |
Referenced by fp_Line::_createMapOfRuns().
#define UT_BIDI_IGNORE FRIBIDI_TYPE_IGNORE |
#define UT_BIDI_IS_LETTER FRIBIDI_IS_LETTER |
Referenced by UT_UCS4_isalpha().
#define UT_BIDI_IS_NEUTRAL FRIBIDI_IS_NEUTRAL |
#define UT_BIDI_IS_NUMBER FRIBIDI_IS_NUMBER |
#define UT_BIDI_IS_RTL FRIBIDI_IS_RTL |
#define UT_BIDI_IS_STRONG FRIBIDI_IS_STRONG |
#define UT_BIDI_IS_WEAK FRIBIDI_IS_WEAK |
#define UT_BIDI_LRE FRIBIDI_TYPE_LRE |
Referenced by fp_Line::_createMapOfRuns().
#define UT_BIDI_LRO FRIBIDI_TYPE_LRO |
Referenced by fp_Line::_createMapOfRuns().
#define UT_BIDI_LTR FRIBIDI_TYPE_LTR |
Referenced by AP_Preview_Paragraph::_appendLine(), IE_Imp_RTF::_appendSpan(), GR_CairoGraphics::_calculateLogicalOffsets(), fp_Line::_calculateWidthOfRun(), fp_Line::_createMapOfRuns(), fp_Line::_doClearScreenFromRunToEnd(), fp_TextRun::_draw(), fp_TabRun::_drawArrow(), fp_TextRun::_drawFirstChar(), fp_TextRun::_drawLastChar(), IE_Imp_MsWord_97::_flush(), fp_TextRun::_getPartRect(), IE_Imp_RTF::_insertSpan(), fl_BlockLayout::_lookupProperties(), GR_CairoGraphics::_measureExtent(), s_RTF_ListenerWriteDoc::_outputData(), fp_TextRun::_refreshDrawBuffer(), IE_Imp_RTF::buildCharacterProps(), fp_Line::calculateWidthOfTrailingSpaces(), FV_View::cmdCharInsert(), fp_Line::countJustificationPoints(), Defun1(), Defun_EV_GetToolbarItemState_Fn(), fp_TextRun::findPointCoords(), fp_TabRun::findPointCoords(), fl_BlockLayout::formatWrappedFromHere(), fp_Line::genOverlapRects(), fl_BlockLayout::getLeftRightForWrapping(), fl_BlockLayout::getNextWrappedLine(), fp_Run::getVisDirection(), GR_CairoGraphics::justify(), fp_Line::justify(), fp_Line::layout(), Text_Listener::populate(), FV_View::processSelectedBlocks(), fp_Line::recalcMaxWidth(), FV_View::setBlockFormat(), fp_TextRun::setDirOverride(), fp_TextRun::split(), and fl_BlockLayout::StartList().
#define UT_BIDI_NSM FRIBIDI_TYPE_NSM |
Referenced by fp_Line::_createMapOfRuns().
#define UT_BIDI_ON FRIBIDI_TYPE_ON |
Referenced by fp_Line::_createMapOfRuns().
#define UT_BIDI_PDF FRIBIDI_TYPE_PDF |
Referenced by fp_Line::_createMapOfRuns().
#define UT_BIDI_RLE FRIBIDI_TYPE_RLE |
Referenced by fp_Line::_createMapOfRuns().
#define UT_BIDI_RLO FRIBIDI_TYPE_RLO |
Referenced by fp_Line::_createMapOfRuns().
#define UT_BIDI_RTL FRIBIDI_TYPE_RTL |
Referenced by AP_Preview_Paragraph::_appendLine(), IE_Imp_RTF::_appendSpan(), GR_XPRenderInfo::_calculateCharAdvances(), fp_Line::_calculateWidthOfRun(), fp_EndOfParagraphRun::_clearScreen(), fp_DirectionMarkerRun::_clearScreen(), fp_Line::_createMapOfRuns(), fp_Line::_doClearScreenFromRunToEnd(), fp_TextRun::_draw(), fp_EndOfParagraphRun::_draw(), fp_ForcedLineBreakRun::_draw(), IE_Imp_MsWord_97::_flush(), fp_TextRun::_getPartRect(), IE_Imp_RTF::_insertSpan(), GR_CairoGraphics::_measureExtent(), s_RTF_ListenerWriteDoc::_outputData(), fp_TextRun::_refreshDrawBuffer(), GR_XPRenderInfo::_stripLigaturePlaceHolders(), AP_Preview_Paragraph::AP_Preview_Paragraph(), IE_Imp_RTF::ApplyParagraphAttributes(), IE_Imp_RTF::ApplySectionAttributes(), IE_Imp_RTF::buildCharacterProps(), fp_Line::calculateWidthOfRun(), FV_View::cmdCharInsert(), GR_XPRenderInfo::cut(), Defun1(), AP_Lists_preview::draw(), fl_BlockLayout::findNextTabStop(), fp_TextRun::findPointCoords(), fl_BlockLayout::findPrevTabStop(), fl_BlockLayout::getListPropertyVector(), fp_Run::getOffsetFirstVis(), fp_Run::getOffsetLog(), fl_BlockLayout::getPreviousListOfSameMargin(), fp_Run::getVisPosition(), fp_Line::getWorkingDirectionAndTabstops(), GR_CairoGraphics::justify(), fp_Line::layout(), fp_TextRun::mapXYToPosition(), GR_CairoGraphics::measureString(), Text_Listener::populate(), GR_CairoGraphics::renderChars(), FV_View::setBlockFormat(), fp_TextRun::setDirOverride(), XAP_DiskStringSet::setValue(), GR_Win32USPGraphics::shape(), GR_Graphics::shape(), GR_CairoGraphics::shape(), fl_BlockLayout::StartList(), and fl_BlockLayout::StopListInBlock().
#define UT_BIDI_SS FRIBIDI_TYPE_SS |
Referenced by fp_Line::_createMapOfRuns().
#define UT_BIDI_UNSET FRIBIDI_TYPE_UNSET |
Referenced by IE_Imp_RTF::_appendSpan(), s_RTF_ListenerWriteDoc::_closeBlock(), IE_Imp_MsWord_97::_flush(), IE_Imp_RTF::_insertSpan(), fp_TextRun::_lookupProperties(), fl_BlockLayout::_lookupProperties(), fl_BlockLayout::_stuffAllRunsOnALine(), fp_Line::addDirectionUsed(), IE_Imp_RTF::ApplySectionAttributes(), fp_Line::changeDirectionUsed(), fp_TextRun::fp_TextRun(), fp_Run::getVisDirection(), fp_Line::removeDirectionUsed(), fp_TextRun::setDirection(), fp_TextRun::setDirOverride(), and fp_Run::setVisDirection().
#define UT_BIDI_WS FRIBIDI_TYPE_WS |
Referenced by fp_Line::_createMapOfRuns(), fp_TabRun::_lookupProperties(), fp_DummyRun::_lookupProperties(), fp_FmtMarkRun::_lookupProperties(), fp_AnnotationRun::fp_AnnotationRun(), fp_BookmarkRun::fp_BookmarkRun(), fp_HyperlinkRun::fp_HyperlinkRun(), fp_RDFAnchorRun::fp_RDFAnchorRun(), and fp_Run::setDirection().
#define UT_strptime strptime |
Referenced by ODc_reorderDate(), and parseTimeString().
Referenced by whatKindOfChar().
typedef FriBidiCharType UT_BidiCharType |
ABI_EXPORT const char* std_size_string | ( | float | f | ) |
ABI_EXPORT UT_BidiCharType UT_bidiGetCharType | ( | UT_UCS4Char | c | ) |
Referenced by IE_Imp_RTF::_appendSpan(), IE_Imp_MsWord_97::_flush(), IE_Imp_Text::_insertSpan(), IE_Imp_RTF::_insertSpan(), fp_TextRun::breakMeAtDirBoundaries(), fp_TextRun::breakNeighborsAtDirBoundaries(), EV_Toolbar_Label::EV_Toolbar_Label(), fp_DirectionMarkerRun::fp_DirectionMarkerRun(), AP_Dialog_MarkRevisions::getComment1(), AP_Dialog_ListRevisions::getNthItemText(), GR_Graphics::itemize(), Text_Listener::populate(), fp_TextRun::setDirection(), AP_DiskStringSet::setValue(), and UT_UCS4_isalpha().
ABI_EXPORT bool UT_bidiGetMirrorChar | ( | UT_UCS4Char | c, | |
UT_UCS4Char & | mc | |||
) |
Referenced by s_getMirrorChar().
ABI_EXPORT bool UT_bidiMapLog2Vis | ( | const UT_UCS4Char * | pStrIn, | |
UT_uint32 | len, | |||
UT_BidiCharType | baseDir, | |||
UT_uint32 * | pL2V, | |||
UT_uint32 * | pV2L, | |||
UT_Byte * | pEmbed | |||
) |
References UT_ASSERT_HARMLESS, and UT_return_val_if_fail.
Referenced by fp_Line::_createMapOfRuns().
ABI_EXPORT bool UT_bidiReorderString | ( | const UT_UCS4Char * | pStrIn, | |
UT_uint32 | len, | |||
UT_BidiCharType | baseDir, | |||
UT_UCS4Char * | pStrOut | |||
) |
pStrOut needs to contain space for len characters + terminating 0
References UT_ASSERT_HARMLESS, UT_return_val_if_fail, and UT_UCS4_strncpy().
Referenced by AP_Preview_Paragraph::_appendLine(), fp_FieldRun::_setValue(), AP_Lists_preview::draw(), EV_Toolbar_Label::EV_Toolbar_Label(), AP_Dialog_MarkRevisions::getComment1(), AP_Dialog_ListRevisions::getNthItemText(), XAP_DiskStringSet::setValue(), and AP_DiskStringSet::setValue().
ABI_EXPORT void UT_decodeUTF8string | ( | const gchar * | p, | |
UT_uint32 | len, | |||
UT_GrowBuf * | pResult | |||
) |
References UT_GrowBuf::append(), gchar, and UT_ASSERT.
Referenced by XAP_Prefs::savePrefsFile(), XAP_DiskStringSet::setValue(), and AP_DiskStringSet::setValue().
ABI_EXPORT bool UT_ensureValidXML | ( | std::string & | str | ) |
Ensure a key or property is valid XML.
Return true if it was and false if it needed fixing.
Ensure a key or property is valid XML.
This function removes any illegal characters and invalid utf-8 sequences.
str | the string to modify in place |
%true | if the string was valid before. false if it needed changes. |
References gchar, s, UT_ASSERT_HARMLESS, UT_NOT_IMPLEMENTED, and xxx_UT_DEBUGMSG.
Referenced by PP_AttrProp::setAttribute(), PP_AttrProp::setProperty(), and TFTEST_MAIN().
ABI_EXPORT bool UT_isSmartQuotableCharacter | ( | UT_UCSChar | c | ) |
ABI_EXPORT bool UT_isSmartQuotedCharacter | ( | UT_UCSChar | c | ) |
References UCS_LDBLQUOTE, UCS_LQUOTE, UCS_RDBLQUOTE, and UCS_RQUOTE.
Referenced by fp_TextRun::isOneItem().
ABI_EXPORT bool UT_isValidXML | ( | const char * | pString | ) |
s | The string of characters which is to be checked for XML-validity. |
TRUE | if the characters are all valid for XML, FALSE if any one of them is not. |
NB: this function also checks that the string is valid utf-8
References s.
Referenced by TFTEST_MAIN().
ABI_EXPORT void UT_parse_attributes | ( | const char * | attributes, | |
std::map< std::string, std::string > & | map | |||
) |
References s_pass_name(), s_pass_string(), and s_pass_whitespace().
ABI_EXPORT void UT_parse_properties | ( | const char * | props, | |
std::map< std::string, std::string > & | map | |||
) |
References s_pass_name(), s_pass_value(), and s_pass_whitespace().
Referenced by AP_Convert::print(), IE_Imp::setProps(), and IE_Exp::setProps().
ABI_EXPORT UT_uint32 UT_UCS2_strlen | ( | const UT_UCS2Char * | string | ) |
Referenced by IE_Imp_MsWord_97::_getBookmarkName().
ABI_EXPORT bool UT_UCS4_cloneString | ( | UT_UCS4Char ** | dest, | |
const UT_UCS4Char * | src | |||
) |
References UT_calloc(), and UT_UCS4_strlen().
Referenced by AP_UnixDialog_Spell::_convertFromMB(), AP_Dialog_Paragraph::_createPreviewFromGC(), AP_Dialog_Replace::_manageList(), FV_View::findGetFindString(), FV_View::findGetReplaceString(), FV_View::findSetFindString(), FV_View::findSetReplaceString(), XAP_Dialog_FontChooser::setDrawString(), XAP_Preview_Zoom::setString(), AP_Preview_Paragraph_Block::setText(), XAP_Dictionary::suggestWord(), BarbarismChecker::suggestWord(), and utf8_to_utf32().
ABI_EXPORT bool UT_UCS4_cloneString_char | ( | UT_UCS4Char ** | dest, | |
const char * | src | |||
) |
References UT_calloc(), and UT_UCS4_strcpy_char().
Referenced by fp_Line::_calculateWidthOfRun(), fp_ForcedPageBreakRun::_draw(), fp_ForcedColumnBreakRun::_draw(), AP_Preview_PageNumbers::AP_Preview_PageNumbers(), XAP_Dialog_FontChooser::event_previewExposed(), ODe_Style_Style::ParagraphProps::fetchAttributesFromAbiProps(), FV_View::findGetFindString(), FV_View::findGetReplaceString(), AP_Dialog_Replace::getFindString(), AP_Dialog_Replace::getReplaceString(), s_doInsertDateTime(), s_getUCSText(), XAP_Dialog_FontChooser::setDrawString(), XAP_Preview_Zoom::setString(), XAP_FontPreview::setText(), XAP_CocoaDialog_FontChooser::updatePreview, XAP_Dialog_FontChooser::XAP_Dialog_FontChooser(), and XAP_FontPreview::XAP_FontPreview().
ABI_EXPORT bool UT_UCS4_isalpha | ( | UT_UCS4Char | c | ) |
References UT_BIDI_IS_LETTER, and UT_bidiGetCharType().
Referenced by FV_View::toggleCase(), UT_isWordDelimiter(), and whatKindOfChar().
ABI_EXPORT bool UT_UCS4_isdigit | ( | UT_UCS4Char | c | ) |
References digits_table, and s_cmp_digits().
Referenced by AP_Win32Dialog_Goto::_onCommand(), IE_Exp_RTF::_write_rtf_header(), and RTF_msword97_level::ParseLevelText().
ABI_EXPORT bool UT_UCS4_islower | ( | UT_UCS4Char | c | ) |
References case_table, s_cmp_case(), and case_entry::type.
Referenced by _toggleToggle(), BarbarismChecker::suggestWord(), and FV_View::toggleCase().
ABI_EXPORT bool UT_UCS4_isSentenceSeparator | ( | UT_UCS4Char | c | ) |
Referenced by fl_BlockLayout::isSentenceSeparator(), and FV_View::toggleCase().
ABI_EXPORT bool UT_UCS4_isspace | ( | UT_UCS4Char | c | ) |
References whitespace_table.
Referenced by FV_View::_isSpaceBefore(), _toggleFirstCapital(), AbiGoogle_invoke(), fp_TextRun::canMergeWithNext(), IE_Imp_Applix::s_getTagName(), s_pass_name(), s_pass_value(), s_pass_whitespace(), FV_View::toggleCase(), UT_UCS4String::UT_UCS4String(), UT_UTF8_Base64Decode(), and whatKindOfChar().
ABI_EXPORT bool UT_UCS4_isupper | ( | UT_UCS4Char | c | ) |
References case_table, s_cmp_case(), and case_entry::type.
Referenced by BarbarismChecker::suggestWord().
ABI_EXPORT UT_sint32 UT_UCS4_strcmp | ( | const UT_UCS4Char * | left, | |
const UT_UCS4Char * | right | |||
) |
References UT_ASSERT.
Referenced by AP_Dialog_Replace::_manageList(), fp_FieldRun::_setValue(), operator<(), operator==(), IE_Imp_RTF::ReadRevisionTable(), and AP_Dialog_Replace::setFindString().
ABI_EXPORT UT_UCS4Char* UT_UCS4_strcpy | ( | UT_UCS4Char * | dest, | |
const UT_UCS4Char * | src | |||
) |
References UT_ASSERT.
Referenced by fp_FieldRun::_setValue(), AP_Dialog_Spell::addChangeAll(), and UT_UCS4_strcpy_utf8_char().
ABI_EXPORT UT_UCS4Char* UT_UCS4_strcpy_char | ( | UT_UCS4Char * | dest, | |
const char * | src | |||
) |
References XAP_EncodingManager::get_instance(), UT_UCS4_mbtowc::mbtowc(), and UT_ASSERT.
Referenced by AP_TopRuler::_drawTickMark(), AP_Dialog_Styles::_populateAbiPreview(), XAP_Win32Dialog_Insert_Symbol::_setFontFromCombo(), XAP_Dictionary::addWord(), fp_FieldShortFileNameRun::calculateValue(), fp_FieldFileNameRun::calculateValue(), fp_FieldDateRun::calculateValue(), fp_FieldTimeRun::calculateValue(), fp_FieldEndnoteRefRun::calculateValue(), fp_FieldEndnoteAnchorRun::calculateValue(), fp_FieldFootnoteAnchorRun::calculateValue(), fp_FieldFootnoteRefRun::calculateValue(), fp_FieldTimeZoneRun::calculateValue(), fp_FieldDateTimeCustomRun::calculateValue(), fp_FieldAMPMRun::calculateValue(), fp_FieldMilTimeRun::calculateValue(), fp_FieldDOYRun::calculateValue(), fp_FieldWkdayRun::calculateValue(), fp_FieldDefaultDateNoTimeRun::calculateValue(), fp_FieldDefaultDateRun::calculateValue(), fp_FieldMthDayYearRun::calculateValue(), fp_FieldMonthDayYearRun::calculateValue(), fp_FieldDDMMYYRun::calculateValue(), fp_FieldMMDDYYRun::calculateValue(), AP_LeftRuler::drawLU(), AbiCommand::insertText(), UT_UCS4String::operator+=(), AbiCommand::parseTokens(), AbiCommand::replaceAll(), AbiCommand::replaceNext(), AP_Win32App::s_fromWinLocaleToUCS4(), fd_Field::update(), and UT_UCS4_cloneString_char().
ABI_EXPORT char* UT_UCS4_strcpy_to_char | ( | char * | dest, | |
const UT_UCS4Char * | src | |||
) |
References XAP_EncodingManager::get_instance(), UT_ASSERT, and UT_Wctomb::wctomb_or_fallback().
Referenced by AP_CocoaDialog_Replace::_populateWindowData, XAP_Dictionary::addWord(), AP_Dialog_MarkRevisions::getComment1(), AP_Dialog_ListRevisions::getNthItemText(), and AP_Dialog_InsertHyperlink::setDoc().
ABI_EXPORT UT_UCS4Char* UT_UCS4_strcpy_utf8_char | ( | UT_UCS4Char * | dest, | |
const char * | src | |||
) |
ABI_EXPORT UT_UCS4Char* UT_UCS4_stristr | ( | const UT_UCS4Char * | phaystack, | |
const UT_UCS4Char * | pneedle | |||
) |
References UT_UCS4_tolower().
ABI_EXPORT UT_uint32 UT_UCS4_strlen | ( | const UT_UCS4Char * | string | ) |
Referenced by AP_Win32Dialog_Spell::_change(), AP_Win32Dialog_Spell::_changeAll(), EV_Win32Toolbar::_ComboWndProc(), FV_View::_computeFindPrefix(), fp_FieldRun::_defaultDraw(), fp_EndOfParagraphRun::_draw(), fp_ForcedLineBreakRun::_draw(), fp_Run::_drawTextLine(), FV_View::_findNext(), FV_View::_findPrev(), FV_View::_findReplace(), FV_View::_findReplaceReverse(), s_AbiWord_1_Listener::_handleRevisions(), fp_EndOfParagraphRun::_lookupProperties(), fp_ForcedLineBreakRun::_lookupProperties(), AP_Win32Dialog_Replace::_onCommand(), AP_Dialog_Styles::_populateAbiPreview(), AP_CocoaDialog_Replace::_populateWindowData, fp_FieldRun::_recalcWidth(), fp_FieldRun::_setValue(), AP_Win32Dialog_Spell::_showMisspelledWord(), _ucs4ToLatin1(), _ucsToAscii(), _ucsToUTF8(), s_RTF_ListenerWriteDoc::_writeFieldTrailer(), AP_Dialog_Spell::addChangeAll(), AP_Dialog_MarkRevisions::addRevision(), AiksaurusABI_ucsToAscii(), fp_FieldListLabelRun::calculateValue(), AP_Dialog_Spell::changeWordWith(), XAP_Dictionary::countCommonChars(), XAP_Preview_Zoom::draw(), XAP_Preview_FontPreview::draw(), AP_Preview_PageNumbers::draw(), AP_Lists_preview::draw(), XAP_Dialog_FontChooser::event_previewExposed(), UT_Win32LocaleString::fromUCS4(), AP_Dialog_MarkRevisions::getComment1(), AP_Dialog_Lists::getListLabel(), AP_Dialog_ListRevisions::getNthItemText(), FV_View::gotoTarget(), AP_UnixDialog_Spell::onChangeAllClicked(), AP_UnixDialog_Spell::onChangeClicked(), UT_UCS4String::operator+=(), UT_UCS4String::operator=(), AP_Dialog_Lists::PopulateDialogData(), s_doInsertDateTime(), XAP_Dictionary::save(), XAP_Dialog_FontChooser::setDrawString(), AP_Preview_Paragraph_Block::setText(), BarbarismChecker::suggestExactWord(), XAP_Dictionary::suggestWord(), fd_Field::update(), UT_UCS4_cloneString(), and IE_Exp_OpenXML::writeText().
ABI_EXPORT UT_uint32 UT_UCS4_strlen_as_char | ( | const UT_UCS4Char * | string | ) |
References XAP_EncodingManager::get_instance(), and UT_Wctomb::wctomb_or_fallback().
Referenced by AP_Dialog_InsertHyperlink::setDoc().
ABI_EXPORT UT_UCS4Char* UT_UCS4_strncpy | ( | UT_UCS4Char * | dest, | |
const UT_UCS4Char * | src, | |||
UT_uint32 | n | |||
) |
References UT_ASSERT.
Referenced by AD_Document::addRevision(), GR_XPRenderInfo::append(), PD_Document::changeDocPropeties(), GR_XPRenderInfo::cut(), GR_XPRenderInfo::split(), and UT_bidiReorderString().
ABI_EXPORT UT_UCS4Char* UT_UCS4_strncpy_char | ( | UT_UCS4Char * | dest, | |
const char * | src, | |||
int | ||||
) |
References XAP_EncodingManager::get_instance(), UT_UCS4_mbtowc::mbtowc(), and UT_ASSERT.
ABI_EXPORT char* UT_UCS4_strncpy_to_char | ( | char * | dest, | |
const UT_UCS4Char * | src, | |||
int | ||||
) |
References XAP_EncodingManager::get_instance(), UT_ASSERT, and UT_Wctomb::wctomb_or_fallback().
Referenced by AP_Dialog_Spell::addChangeAll(), and AP_Dialog_Spell::inChangeAll().
ABI_EXPORT UT_UCS4Char* UT_UCS4_strnrev | ( | UT_UCS4Char * | dest, | |
UT_uint32 | n | |||
) |
Referenced by fp_TextRun::_refreshDrawBuffer().
ABI_EXPORT UT_UCS4Char* UT_UCS4_strstr | ( | const UT_UCS4Char * | phaystack, | |
const UT_UCS4Char * | pneedle | |||
) |
Referenced by XAP_Dictionary::countCommonChars().
ABI_EXPORT UT_UCS4Char UT_UCS4_tolower | ( | UT_UCS4Char | c | ) |
References case_table, XAP_EncodingManager::get_instance(), case_entry::other, s_cmp_case(), and case_entry::type.
Referenced by IE_Imp_MsWord_97::_appendChar(), FV_View::_computeFindPrefix(), FV_View::_findNext(), FV_View::_findPrev(), _toggleFirstCapital(), _toggleLower(), _toggleToggle(), ev_Win32Keyboard::onKeyDown(), BarbarismChecker::suggestWord(), and UT_UCS4_stristr().
ABI_EXPORT UT_UCS4Char UT_UCS4_toupper | ( | UT_UCS4Char | c | ) |
Convert a given character to uppercase.
References case_table, XAP_EncodingManager::get_instance(), case_entry::other, s_cmp_case(), and case_entry::type.
Referenced by _toggleFirstCapital(), _toggleToggle(), _toggleUpper(), BarbarismChecker::suggestWord(), and FV_View::toggleCase().
ABI_EXPORT bool UT_validXML | ( | char * | pString | ) |
XML cannot contain any control characters except ,
, , see bug 8565 (http://www.w3.org/TR/REC-xml/#charsets)
This function removes any illegal characters and invalid utf-8 sequences.
The return value of true indicates that the string was modified
References UT_String::c_str(), gchar, UT_String::length(), UT_String::reserve(), s, UT_ASSERT, UT_ASSERT_HARMLESS, and UT_NOT_IMPLEMENTED.
Referenced by TFTEST_MAIN().
ABI_EXPORT bool UT_XML_cloneConvAmpersands | ( | gchar *& | rszDest, | |
const gchar * | szSource | |||
) |
References gchar, and UT_calloc().
Referenced by localizeMenuItem().
G_BEGIN_DECLS ABI_EXPORT bool UT_XML_cloneNoAmpersands | ( | gchar *& | rszDest, | |
const gchar * | szSource | |||
) |
References gchar, and UT_calloc().
ABI_EXPORT const gchar* UT_XML_transNoAmpersands | ( | const gchar * | szSource | ) |
References gchar, and UT_calloc().