MCPcopy Create free account
hub / github.com/TeXworks/texworks / addPage

Method addPage

modules/QtPDF/src/PDFPageLayout.cpp:93–113  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

91}
92
93void PDFPageLayout::addPage(PDFPageGraphicsItem * page) {
94 LayoutItem item;
95
96 if (!page)
97 return;
98
99 item.page = page;
100 if (_layoutItems.isEmpty()) {
101 item.row = 0;
102 item.col = _firstCol;
103 }
104 else if (_layoutItems.last().col < _numCols - 1){
105 item.row = _layoutItems.last().row;
106 item.col = _layoutItems.last().col + 1;
107 }
108 else {
109 item.row = _layoutItems.last().row + 1;
110 item.col = 0;
111 }
112 _layoutItems.append(item);
113}
114
115void PDFPageLayout::removePage(PDFPageGraphicsItem * page) {
116 QList<LayoutItem>::iterator it;

Callers 1

reinitializeSceneMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected