small class which defines a vector with 2 elements More...
#include <libwps_internal.h>
Classes | |
struct | PosSizeLtX |
internal struct used to create sorted map, sorted by X More... | |
struct | PosSizeLtY |
internal struct used to create sorted map, sorted by Y More... | |
Public Member Functions | |
Vec2 (T xx=0, T yy=0) | |
constructor | |
template<class U > | |
Vec2 (Vec2< U > const &p) | |
generic copy constructor | |
T | x () const |
first element | |
T | y () const |
second element | |
T | operator[] (int c) const |
operator[] | |
T & | operator[] (int c) |
operator[] | |
void | set (T xx, T yy) |
resets the two elements | |
void | setX (T xx) |
resets the first element | |
void | setY (T yy) |
resets the second element | |
void | add (T dx, T dy) |
increases the actuals values by dx and dy | |
Vec2< T > & | operator+= (Vec2< T > const &p) |
operator+= | |
Vec2< T > & | operator-= (Vec2< T > const &p) |
operator-= | |
template<class U > | |
Vec2< T > & | operator*= (U scale) |
generic operator*= | |
bool | operator== (Vec2< T > const &p) const |
comparison== | |
bool | operator!= (Vec2< T > const &p) const |
comparison!= | |
bool | operator< (Vec2< T > const &p) const |
comparison<: sort by y | |
int | cmp (Vec2< T > const &p) const |
a comparison function: which first compares x then y | |
int | cmpY (Vec2< T > const &p) const |
a comparison function: which first compares y then x | |
Protected Attributes | |
T | m_x |
first element | |
T | m_y |
second element | |
Friends | |
Vec2< T > | operator+ (Vec2< T > const &p1, Vec2< T > const &p2) |
operator+ | |
Vec2< T > | operator- (Vec2< T > const &p1, Vec2< T > const &p2) |
operator- | |
template<class U > | |
Vec2< T > | operator* (U scale, Vec2< T > const &p1) |
generic operator* | |
std::ostream & | operator<< (std::ostream &o, Vec2< T > const &f) |
operator<<: prints data in form "XxY" | |
small class which defines a vector with 2 elements
constructor
Referenced by Quattro9SpreadsheetInternal::Column::add(), LotusSpreadsheetInternal::Table123Styles::addCellStyle(), LotusSpreadsheetInternal::Table123Styles::addCellStyle(), LotusSpreadsheetInternal::Table123Styles::addCellStyle(), WKSChart::Axis::addContentTo(), WKSChart::Legend::addContentTo(), WKSChart::Serie::addContentTo(), libwps_tools_win::Language::addLocaleName(), WPSGraphicStyle::addTo(), WPSGraphicShape::addTo(), WPSStringStreamPrivate::append(), WPS8Text::bmktEndDataParser(), WPSTable::buildStructures(), LotusParser::checkHeader(), libwps::MultiplanParser::checkHeader(), QuattroParser::checkHeader(), Quattro9Parser::checkHeader(), WKS4Parser::checkHeader(), PocketWordParser::checkUnparsed(), WPSCellFormat::convertDTFormat(), WPS8Struct::FileData::createErrorString(), XYWriteParser::createFormatChildren(), LotusParser::createListener(), libwps::MultiplanParser::createListener(), QuattroParser::createListener(), Quattro9Parser::createListener(), QuattroDosParser::createListener(), WKS4Parser::createListener(), MSWriteParser::createListener(), PocketWordParser::createListener(), WPS4Parser::createListener(), WPS8Parser::createListener(), XYWriteParser::createListener(), WPS8Text::createNotesCorrespondance(), libwps_OLE::IStream::createOleFromDirectory(), WPS8Parser::createOLEStructures(), WPS8Parser::createStructures(), XYWriteParser::createTable(), LotusParser::createZones(), PocketWordParser::createZones(), WPSOLE1Parser::createZones(), Quattro9Parser::decodeStream(), QuattroParser::decodeStream(), WPS4Text::defDataParser(), WPS4Text::dttmDataParser(), libwps_OLE::DirTree::find_child(), WPS4Text::findFDPStructures(), WPS8TextStyle::findFDPStructures(), WPS4Parser::findZones(), libwps_OLE::AllocTable::follow(), WPS4Text::footNotesDataParser(), WPSGraphicShape::PathData::get(), libwps_OLE::DirTree::get_siblings(), WPSGraphicStyle::Pattern::getBinary(), WPS8Struct::FileData::getBorderStyles(), WPSTable::getCell(), WKSChart::Position::getCellName(), LotusChartInternal::State::getChart(), libwps::MultiplanParserInternal::State::getColumnsWidth(), LotusParserInternal::State::getDataZoneIdToSheetIdMap(), Quattro9ParserInternal::TextEntry::getDebugString(), LotusSpreadsheet::getDebugStringForText(), libwps_tools_win::Font::getFontType(), QuattroGraph::getGraphicCellsInSheet(), WPSOLEParser::getIdFromDirectory(), LotusParserInternal::State::getLevelsDebugName(), LotusParser::getLinksList(), Quattro9SpreadsheetInternal::Spreadsheet::getListCellsInARow(), Quattro9SpreadsheetInternal::Spreadsheet::getListSendRow(), LotusChart::getNameToChartIdMap(), libwps_OLE::getOLEInputStream(), WPSGraphicShape::getPath(), Quattro9Spreadsheet::getReadCellReferenceFunction(), QuattroSpreadsheet::getReadCellReferenceFunction(), QuattroSpreadsheetInternal::State::getSheet(), QuattroDosSpreadsheetInternal::State::getSheet(), WKS4SpreadsheetInternal::State::getSheet(), WPSOLE1Parser::getStream(), WPSOLE1Parser::getStreamForId(), WPSOLE1Parser::getStreamForName(), Quattro9ParserInternal::TextEntry::getString(), libwps_OLE::WPSOLEStream::getSubStreamByName(), libwps_OLE::DirTree::getSubStreamList(), libwps_OLE::DirTree::getSubStreamList(), libwps_OLE::IStorage::getSubStreamNamesList(), libwps_tools_win::Font::getTypeForString(), QuattroDosSpreadsheetInternal::State::getUniqueSheetName(), QuattroSpreadsheetInternal::State::getUniqueSheetName(), LotusSpreadsheetInternal::Spreadsheet::getWidths(), Quattro9SpreadsheetInternal::Spreadsheet::getWidths(), QuattroDosSpreadsheetInternal::Spreadsheet::getWidths(), QuattroSpreadsheetInternal::Spreadsheet::getWidths(), WKS4SpreadsheetInternal::Spreadsheet::getWidths(), LotusParserInternal::State::getZone1StackDebugName(), WKSContentListener::handleSubDocument(), WPSContentListener::handleSubDocument(), libwps_OLE::DirTree::index(), QuattroParserInternal::State::initZoneNameMap(), Quattro9ParserInternal::State::initZoneNameMap(), WKSContentListener::insertChart(), libwps_OLE::OStorage::insertData(), libwps::WPSDocument::isFileFormatSupported(), libwps_OLE::IStorage::load(), libwps_OLE::DirEntry::load(), libwps_OLE::IStorage::loadBigBlock(), libwps_OLE::IStorage::loadSmallBlock(), libwps_OLE::IStorage::loadSmallBlocks(), WPSTextParser::mergeSortedFODLists(), libwps_tools_win::Language::name(), WKSContentListener::openSheetCell(), libwps_OLE::DirTree::CompareEntryName::operator()(), libwps::WPSDocument::parse(), libwps::WPSDocument::parse(), LotusParser::parse(), QuattroDosParser::parse(), WKS4Parser::parse(), WPSOLEParser::parse(), WPS4Parser::parseEntry(), XYWriteParser::parseFormat(), LotusParser::parseFormatStream(), XYWriteParser::parseFrameZone(), WPS8Parser::parseHeaderIndex(), WPS8Parser::parseHeaderIndexEntry(), XYWriteParser::parseMetaData(), QuattroParser::parseOLEStream(), Quattro9Parser::parseOLEStream(), XYWriteParser::parsePictureZone(), XYWriteParser::parseTextZone(), LotusSpreadsheet::parseVariable(), MSWriteParser::processEmbeddedOLE(), MSWriteParser::processObject(), MSWriteParser::processStaticOLE(), WPS8Struct::FileData::readArrayBlock(), WPS8Graph::readBDR(), Quattro9Graph::readBeginEnd(), Quattro9Graph::readBeginEndZone(), QuattroGraph::readBitmap(), XYWriteParserInternal::Format::readBox2f(), QuattroGraph::readButton(), QuattroDosSpreadsheet::readCell(), WKS4Spreadsheet::readCell(), QuattroSpreadsheet::readCell(), LotusSpreadsheet::readCell(), WKS4Spreadsheet::readCell(), libwps::MultiplanParser::readCellDataPosition(), Quattro9Spreadsheet::readCellList(), LotusSpreadsheet::readCellName(), QuattroDosSpreadsheet::readCellProperty(), LotusSpreadsheet::readCellsFormat801(), QuattroDosSpreadsheet::readCellStyle(), QuattroSpreadsheet::readCellStyle(), LotusStyleManager::readCellStyleD2(), LotusStyleManager::readCellStyleD2Data(), LotusStyleManager::readCellStyleE6(), Quattro9Spreadsheet::readCellStyles(), QuattroDosChart::readChart(), WKS4Chart::readChart(), LotusChart::readChart(), QuattroGraph::readChart(), WKS4Chart::readChart2Font(), WKS4Chart::readChart3D(), WKS4Chart::readChartAxis(), WKS4Chart::readChartDim(), WKS4Chart::readChartFont(), LotusChart::readChartName(), WKS4Chart::readChartSeries(), WKS4Chart::readChartSeriesStyles(), LotusParser::readChartZone(), XYWriteParserInternal::Format::readColor(), LotusStyleManager::readColorStyle(), LotusSpreadsheet::readColumnSizes(), WPSOLEParser::readCompObj(), WPSOLEParser::readContents(), WPSOLEParser::readCONTENTS(), WKS4Parser::readCString(), QuattroParser::readCString(), LotusParser::readDataZone(), QuattroGraph::readDialog(), QuattroGraph::readDialogUnknown(), WPS8Parser::readDocProperties(), Quattro9Parser::readDocumentFields(), WPS4Parser::readDocWindowsInfo(), WPS4Text::readDosLink(), libwps::MultiplanParser::readDouble(), WPSOLEObject::readEmbeddedOLE(), WPS4Text::readEntries(), LotusSpreadsheet::readExtraRowFormats(), WPSTextParser::readFDP(), QuattroParser::readFieldName(), libwps::MultiplanParser::readFilename(), Quattro9Parser::readFilePositions(), QuattroGraph::readFillData(), WKS4Spreadsheet::readFilterOpen(), LotusStyleManager::readFMTFontName(), LotusGraph::readFMTPictName(), LotusParser::readFMTStyleName(), WKS4Parser::readFont(), WPS4Text::readFont(), WPS8TextStyle::readFont(), QuattroDosParser::readFont(), QuattroParser::readFontDef(), WKS4Format::readFontName(), PocketWordParser::readFontNames(), WPS4Text::readFontNames(), WPS8TextStyle::readFontNames(), LotusStyleManager::readFontStyleA0(), LotusStyleManager::readFontStyleF0(), WPS4Text::readFootNotes(), LotusStyleManager::readFormatStyle(), QuattroDosSpreadsheet::readFormula(), WKS4Spreadsheet::readFormula(), QuattroFormulaManager::readFormula(), libwps::MultiplanParser::readFormula(), LotusSpreadsheet::readFormula(), libwps::MultiplanParser::readFormulaV2(), WPS8Parser::readFRAM(), LotusGraph::readFrame(), QuattroGraph::readFrame(), Quattro9Graph::readFrameHeader(), QuattroGraph::readFrameOLE(), libwps::MultiplanParser::readFunctionNamesList(), LotusGraph::readGraphDataZone(), Quattro9Graph::readGraphHeader(), LotusGraph::readGraphic(), LotusStyleManager::readGraphicStyle(), LotusStyleManager::readGraphicStyleC9(), LotusGraph::readGraphZone(), QuattroDosParser::readHeaderFooter(), WPS8Graph::readIBGF(), QuattroGraph::readImage(), QuattroGraph::readLine(), LotusStyleManager::readLineStyle(), libwps::MultiplanParser::readLink(), LotusChart::readMacFloor(), LotusChart::readMacHeader(), LotusChart::readMacLegend(), LotusChart::readMacPlacement(), LotusChart::readMacPlotArea(), LotusChart::readMacSerie(), WPS8Table::readMCLD(), LotusStyleManager::readMenuStyleE7(), WPSOLEObject::readMetafile(), WPSOLEParser::readMN0AndCheckWKS(), WKS4Spreadsheet::readMsWorksDOSCellExtraProperty(), WKS4Spreadsheet::readMsWorksStyle(), libwps::MultiplanParser::readName(), LotusSpreadsheet::readNote(), WPS8Text::readNotes(), XYWriteParserInternal::Format::readNumber(), WPS4Graph::readObject(), WPSOLEParser::readOle10Native(), QuattroGraph::readOLEData(), Quattro9Parser::readOleLinkInfo(), QuattroParser::readOleLinkInfo(), Quattro9Graph::readOLEName(), WPSOLEParser::readOlePres(), QuattroParser::readOLEZones(), Quattro9Spreadsheet::readPageBreak(), PocketWordParser::readPageDims(), WPS4Text::readParagraph(), WPS8TextStyle::readParagraph(), PocketWordParser::readParagraphUnkn(), WPS8Graph::readPICT(), LotusGraph::readPictureData(), LotusGraph::readPictureDefinition(), WPS8Text::readPLC(), WPS4Text::readPLC(), LotusChart::readPlotArea(), QuattroGraph::readPolygon(), WKS4Parser::readPrn2(), WKS4Parser::readPrnt(), WPS4Parser::readPrnt(), QuattroDosParser::readPString(), QuattroGraph::readRect(), LotusParser::readRefZone(), WKS4Spreadsheet::readReportOpen(), LotusSpreadsheet::readRowFormat(), LotusSpreadsheet::readRowFormats(), LotusChart::readSerie(), QuattroParser::readSerieExtension(), LotusChart::readSerieName(), WPS8TextStyle::readSGP(), QuattroGraph::readShape(), QuattroGraph::readShapeHeader(), Quattro9Graph::readShapeRec(), libwps::MultiplanParser::readSharedData(), LotusSpreadsheet::readSheetName(), LotusSpreadsheet::readSheetName1B(), QuattroDosSpreadsheet::readSheetSize(), WKS4Spreadsheet::readSheetSize(), LotusParser::readSheetZone(), PocketWordParser::readSound(), PocketWordParser::readSoundData(), QuattroDosSpreadsheet::readSpreadsheetOpen(), WPSOLEObject::readStaticOLE(), MSWriteParser::readString(), WPS4Text::readStructures(), WPS8Text::readStructures(), WPS8TextStyle::readStructures(), WPS8TextStyle::readSTSH(), LotusStyleManager::readStyleE6(), WPSOLEParser::readSummaryInformation(), WPSOLEParser::readSummaryProperty(), WPSOLEParser::readSummaryPropertyString(), WPS4Text::readText(), WPS8Text::readText(), QuattroGraph::readTextBox(), Quattro9Graph::readTextboxStyle(), Quattro9Parser::readTextFontStyles(), PocketWordParser::readUnkn8(), QuattroDosParser::readUnknown1(), WKS4Parser::readUnknown1(), QuattroDosSpreadsheet::readUserStyle(), libwps_OLE::IStream::readUsingStorage(), XYWriteParserInternal::Format::readVec2f(), XYWriteParserInternal::Format::readVec2i(), LotusParser::readVersionZone(), QuattroSpreadsheet::readViewInfo(), WPSOLEObject::readWMF(), WPS8Parser::readWNPR(), QuattroDosParser::readZone(), WKS4Parser::readZone(), WKS4Format::readZone(), LotusParser::readZone(), QuattroParser::readZone(), Quattro9Parser::readZone(), LotusParser::readZone1(), LotusParser::readZone4(), LotusParser::readZone7(), LotusParser::readZone8(), LotusGraph::readZoneData(), WKS4Parser::readZoneQuattro(), libwps::MultiplanParser::readZones(), QuattroParser::readZones(), Quattro9Parser::readZones(), LotusParser::readZones(), libwps::MultiplanParser::readZonesList(), libwps::MultiplanParser::readZonesListV2(), LotusParser::readZoneV3(), libwps::MultiplanParser::retrievePasswordKeys(), LotusParser::retrievePasswordKeys(), WPSGraphicShape::rotate(), WPSGraphicShape::PathData::rotate(), QuattroGraph::send(), Quattro9ParserInternal::TextEntry::send(), libwps::MultiplanParser::sendCell(), LotusSpreadsheet::sendCellContent(), Quattro9Spreadsheet::sendCellContent(), QuattroDosSpreadsheet::sendCellContent(), QuattroSpreadsheet::sendCellContent(), WKS4Spreadsheet::sendCellContent(), WKSChart::sendChart(), PocketWordParser::sendData(), QuattroGraph::sendGraphic(), LotusGraph::sendGraphics(), QuattroDosParser::sendHeaderFooter(), PocketWordParser::sendParagraph(), LotusSpreadsheet::sendRowContent(), LotusSpreadsheet::sendSpreadsheet(), Quattro9Spreadsheet::sendSpreadsheet(), WKS4Spreadsheet::sendSpreadsheet(), WPSTable::sendTable(), LotusSpreadsheet::sendText(), QuattroDosChart::sendText(), Quattro9Graph::sendTextbox(), QuattroGraph::sendTextbox(), LotusGraph::sendTextBox(), LotusGraph::sendTextBoxWK4(), LotusSpreadsheet::sendTextNote(), LotusGraph::sendZone(), WKSContentListener::setDocumentLanguage(), WPSContentListener::setDocumentLanguage(), libwps_OLE::DirTree::setInRedBlackTreeForm(), libwps_OLE::DirTree::setInRedBlackTreeForm(), WPSContentListener::setParagraph(), MSWriteParser::startSection(), QuattroDosSpreadsheetInternal::State::State(), WKS4SpreadsheetInternal::State::State(), Quattro9GraphInternal::State::storeGraph(), QuattroGraphInternal::State::storeGraph(), libwps::DebugStream::str(), libwps::strncasecmp(), WPS8Text::tokenEndDataParser(), Quattro9SpreadsheetInternal::Spreadsheet::update(), XYWriteParser::update(), LotusStyleManager::updateCellStyle(), QuattroSpreadsheet::updateCellWithUserFormat(), LotusChart::updateChart(), WPSOLE1Parser::updateEmbeddedObject(), XYWriteParserInternal::Format::updateFont(), WPSOLE1Parser::updateMetaData(), XYWriteParserInternal::Format::updateParagraph(), LotusChart::updateState(), LotusSpreadsheet::updateState(), libwps_OLE::OStorage::updateToSave(), XYWriteParserInternal::Format::upperCase(), libwps_OLE::WPSOLEStream::WPSOLEStream(), and WPSStringStreamPrivate::WPSStringStreamPrivate().
generic copy constructor
increases the actuals values by dx and dy
Referenced by MSWriteParser::processEmbeddedOLE(), WKS4Spreadsheet::readCell(), Quattro9Spreadsheet::readCellList(), QuattroDosSpreadsheet::readCellStyle(), WPSOLEParser::readContents(), WPSOLEParser::readCONTENTS(), WPSOLEObject::readEmbeddedOLE(), WPS8Table::readMCLD(), WPSOLEObject::readMetafile(), WPSOLEParser::readMN0AndCheckWKS(), WKS4Spreadsheet::readMsWorksDOSCellExtraProperty(), WKS4Spreadsheet::readMsWorksDOSCellProperty(), WKS4Spreadsheet::readMsWorksStyle(), WPSOLEParser::readOle10Native(), WPSOLEParser::readOlePres(), WPSOLEObject::readStaticOLE(), QuattroDosSpreadsheet::readUserStyle(), WPSOLEObject::readWMF(), and Quattro9SpreadsheetInternal::Spreadsheet::update().
a comparison function: which first compares x then y
Referenced by WPSGraphicShape::PathData::cmp(), WPSGraphicStyle::Pattern::cmp(), WPSGraphicShape::cmp(), WPSGraphicStyle::cmp(), Vec2< T >::PosSizeLtX::operator()(), WPSBox2< T >::PosSizeLt::operator()(), WPSVec3< T >::PosSizeLt::operator()(), and WPSList::set().
a comparison function: which first compares y then x
Referenced by WPSBox2< T >::cmp(), WPSPosition::cmp(), Vec2< T >::operator!=(), Vec2< T >::PosSizeLtY::operator()(), Vec2< T >::operator<(), and Vec2< T >::operator==().
generic operator*=
comparison<: sort by y
resets the two elements
Referenced by WPSTable::buildStructures(), WPS8Graph::readBDR(), WPS8Graph::sendObjects(), WPSContentListener::setParagraph(), and libwps_OLE::OStorage::updateToSave().
resets the first element
Referenced by WPS8Text::objectDataParser(), WPS8Parser::readFRAM(), WPS8Table::readMCLD(), and WPS8Graph::readPICT().
resets the second element
Referenced by WPS8Text::objectDataParser(), WPS8Parser::readFRAM(), WPS8Table::readMCLD(), and WPS8Graph::readPICT().
generic operator*
operator+
operator-
|
friend |
operator<<: prints data in form "XxY"
first element
Referenced by Vec2< T >::add(), WPSGraphicShape::PathData::cmp(), Vec2< T >::cmp(), Vec2< T >::cmpY(), WPSGraphicShape::getPath(), Vec2< T >::operator*=(), Vec2< T >::operator+=(), Vec2< T >::operator-=(), Vec2< T >::operator[](), Vec2< T >::operator[](), Vec2< T >::set(), Vec2< T >::setX(), and Vec2< T >::x().
second element
Referenced by Vec2< T >::add(), Vec2< T >::cmp(), Vec2< T >::cmpY(), Vec2< T >::operator*=(), Vec2< T >::operator+=(), Vec2< T >::operator-=(), Vec2< T >::operator[](), Vec2< T >::operator[](), Vec2< T >::set(), Vec2< T >::setY(), and Vec2< T >::y().