LibreOffice Module sw (master) 1
Namespaces | Functions | Variables
ww8scan.cxx File Reference
#include <memory>
#include "ww8scan.hxx"
#include "ww8par.hxx"
#include <cassert>
#include <cstddef>
#include <cstring>
#include <algorithm>
#include <i18nlangtag/mslangid.hxx>
#include "sprmids.hxx"
#include <rtl/tencinfo.h>
#include <sal/macros.h>
#include <sal/log.hxx>
#include <osl/diagnose.h>
#include <swerror.h>
#include <comphelper/string.hxx>
#include <unotools/localedatawrapper.hxx>
#include <i18nlangtag/lang.h>
#include <o3tl/safeint.hxx>
#include <tools/stream.hxx>
#include <vcl/settings.hxx>
#include <vcl/svapp.hxx>
Include dependency graph for ww8scan.cxx:

Go to the source code of this file.

Namespaces

namespace  MSOPBString
 

Functions

template<class Sprm >
static constexpr SprmInfoRow InfoRow ()
 
static sal_uInt8 Get_Byte (sal_uInt8 *&p)
 
static sal_uInt16 Get_UShort (sal_uInt8 *&p)
 
static sal_Int16 Get_Short (sal_uInt8 *&p)
 
static sal_uInt32 Get_ULong (sal_uInt8 *&p)
 
static sal_Int32 Get_Long (sal_uInt8 *&p)
 
static bool WW8SkipField (WW8PLCFspecial &rPLCF)
 
static bool WW8GetFieldPara (WW8PLCFspecial &rPLCF, WW8FieldDesc &rF)
 
OUString read_uInt8_BeltAndBracesString (SvStream &rStrm, rtl_TextEncoding eEnc)
 
OUString read_uInt16_BeltAndBracesString (SvStream &rStrm)
 
static bool IsReplaceAllSprm (sal_uInt16 nSpId)
 
static bool IsExpandableSprm (sal_uInt16 nSpId)
 
void WW8ReadSTTBF (bool bVer8, SvStream &rStrm, sal_uInt32 nStart, sal_Int32 nLen, sal_uInt16 nExtraLen, rtl_TextEncoding eCS, std::vector< OUString > &rArray, std::vector< ww::bytes > *pExtraArray, std::vector< OUString > *pValueArray)
 reads array of strings (see MS documentation: String Table stored in File) returns NOT the original pascal strings but an array of converted char* More...
 
static OUString MSOPBString::Read (SvStream &rStream)
 
static void MSOPBString::Write (std::u16string_view aString, SvStream &rStream)
 
static void lcl_checkFontname (OUString &sString)
 
bool checkRead (SvStream &rSt, void *pDest, sal_uInt32 nLength)
 

Variables

const int nSmallestPossibleFib = 326
 

Function Documentation

◆ checkRead()

bool checkRead ( SvStream rSt,
void *  pDest,
sal_uInt32  nLength 
)

◆ Get_Byte()

static sal_uInt8 Get_Byte ( sal_uInt8 *&  p)
static

Definition at line 844 of file ww8scan.cxx.

References n, and p.

Referenced by WW8Dop::WW8Dop().

◆ Get_Long()

static sal_Int32 Get_Long ( sal_uInt8 *&  p)
static

Definition at line 870 of file ww8scan.cxx.

References Get_ULong(), and p.

Referenced by WW8Dop::WW8Dop(), and WW8PLCFx_Fc_FKP::WW8Fkp::WW8Fkp().

◆ Get_Short()

static sal_Int16 Get_Short ( sal_uInt8 *&  p)
static

Definition at line 858 of file ww8scan.cxx.

References Get_UShort(), and p.

Referenced by WW8DopTypography::ReadFromMem(), and WW8Dop::WW8Dop().

◆ Get_ULong()

static sal_uInt32 Get_ULong ( sal_uInt8 *&  p)
static

Definition at line 863 of file ww8scan.cxx.

References n, and p.

Referenced by Get_Long(), and WW8Dop::WW8Dop().

◆ Get_UShort()

static sal_uInt16 Get_UShort ( sal_uInt8 *&  p)
static

Definition at line 851 of file ww8scan.cxx.

References n, and p.

Referenced by Get_Short(), WW8DopTypography::ReadFromMem(), and WW8Dop::WW8Dop().

◆ InfoRow()

template<class Sprm >
static constexpr SprmInfoRow InfoRow ( )
staticconstexpr

Definition at line 437 of file ww8scan.cxx.

References wwSprmParser::L_FIX, and wwSprmParser::L_VAR.

◆ IsExpandableSprm()

static bool IsExpandableSprm ( sal_uInt16  nSpId)
static

Definition at line 2632 of file ww8scan.cxx.

Referenced by WW8PLCFx_Fc_FKP::WW8Fkp::WW8Fkp().

◆ IsReplaceAllSprm()

static bool IsReplaceAllSprm ( sal_uInt16  nSpId)
static

Definition at line 2627 of file ww8scan.cxx.

References NS_sprm::LN_PHugePapx.

Referenced by WW8PLCFx_Fc_FKP::WW8Fkp::WW8Fkp().

◆ lcl_checkFontname()

static void lcl_checkFontname ( OUString &  sString)
static

Definition at line 7136 of file ww8scan.cxx.

References aBuf, n, and comphelper::string::strip().

Referenced by WW8Fonts::WW8Fonts().

◆ read_uInt16_BeltAndBracesString()

OUString read_uInt16_BeltAndBracesString ( SvStream rStrm)

◆ read_uInt8_BeltAndBracesString()

OUString read_uInt8_BeltAndBracesString ( SvStream rStrm,
rtl_TextEncoding  eEnc 
)

◆ WW8GetFieldPara()

static bool WW8GetFieldPara ( WW8PLCFspecial rPLCF,
WW8FieldDesc rF 
)
static

◆ WW8ReadSTTBF()

void WW8ReadSTTBF ( bool  bVer8,
SvStream rStrm,
sal_uInt32  nStart,
sal_Int32  nLen,
sal_uInt16  nExtraLen,
rtl_TextEncoding  eCS,
std::vector< OUString > &  rArray,
std::vector< ww::bytes > *  pExtraArray = nullptr,
std::vector< OUString > *  pValueArray = nullptr 
)

reads array of strings (see MS documentation: String Table stored in File) returns NOT the original pascal strings but an array of converted char*

attention: the extra data of each string are SKIPPED and ignored

Definition at line 4152 of file ww8scan.cxx.

References checkSeek(), i, read_uInt16_PascalString(), read_uInt8_lenPrefixed_uInt8s_ToOString(), read_uInt8s_ToOString(), SvStream::ReadBytes(), SvStream::ReadUChar(), SvStream::ReadUInt16(), SvStream::remainingSize(), rStrm, SAL_MAX_UINT16, SAL_WARN, SvStream::Seek(), SvStream::SeekRel(), and SvStream::Tell().

Referenced by SwWW8ImplReader::CoreLoad(), WW8Glossary::Load(), SwWW8ImplReader::ReadDocVars(), SwWW8ImplReader::ReadRevMarkAuthorStrTabl(), and WW8PLCFx_Book::WW8PLCFx_Book().

◆ WW8SkipField()

static bool WW8SkipField ( WW8PLCFspecial rPLCF)
static

Definition at line 1921 of file ww8scan.cxx.

References WW8PLCFspecial::advance(), WW8PLCFspecial::Get(), pData, and WW8SkipField().

Referenced by WW8GetFieldPara(), and WW8SkipField().

Variable Documentation

◆ nSmallestPossibleFib

const int nSmallestPossibleFib = 326

Definition at line 1564 of file ww8scan.cxx.

Referenced by WW8ScannerBase::WW8Cp2Fc().