Mode | Name | Size | |
d--------- | atwrapper | 551 | logstatsplain |
-rw-r--r-- | auto.pro | 16003 | logstatsplain |
d--------- | bic | 247 | logstatsplain |
d--------- | checkxmlfiles | 132 | logstatsplain |
d--------- | collections | 128 | logstatsplain |
d--------- | compiler | 288 | logstatsplain |
d--------- | compilerwarnings | 222 | logstatsplain |
d--------- | exceptionsafety | 136 | logstatsplain |
d--------- | exceptionsafety_objects | 191 | logstatsplain |
d--------- | gestures | 84 | logstatsplain |
d--------- | guiapplauncher | 292 | logstatsplain |
d--------- | headers | 120 | logstatsplain |
d--------- | languagechange | 134 | logstatsplain |
d--------- | linguist | 144 | logstatsplain |
d--------- | macgui | 194 | logstatsplain |
d--------- | macplist | 145 | logstatsplain |
d--------- | maketestselftest | 100 | logstatsplain |
d--------- | mediaobject | 276 | logstatsplain |
d--------- | mediaobject_wince_ds9 | 90 | logstatsplain |
d--------- | moc | 1776 | logstatsplain |
d--------- | modeltest | 260 | logstatsplain |
-rw-r--r-- | network-settings.h | 12524 | logstatsplain |
d--------- | networkselftest | 137 | logstatsplain |
d--------- | patternistexamplefiletree | 156 | logstatsplain |
d--------- | patternistexamples | 142 | logstatsplain |
d--------- | patternistheaders | 140 | logstatsplain |
d--------- | q3accel | 120 | logstatsplain |
d--------- | q3action | 122 | logstatsplain |
d--------- | q3actiongroup | 132 | logstatsplain |
d--------- | q3buttongroup | 217 | logstatsplain |
d--------- | q3canvas | 168 | logstatsplain |
d--------- | q3checklistitem | 136 | logstatsplain |
d--------- | q3combobox | 126 | logstatsplain |
d--------- | q3cstring | 124 | logstatsplain |
d--------- | q3databrowser | 132 | logstatsplain |
d--------- | q3dateedit | 126 | logstatsplain |
d--------- | q3datetimeedit | 134 | logstatsplain |
d--------- | q3deepcopy | 126 | logstatsplain |
d--------- | q3dict | 118 | logstatsplain |
d--------- | q3dns | 116 | logstatsplain |
d--------- | q3dockwindow | 130 | logstatsplain |
d--------- | q3filedialog | 130 | logstatsplain |
d--------- | q3frame | 120 | logstatsplain |
d--------- | q3groupbox | 126 | logstatsplain |
d--------- | q3hbox | 118 | logstatsplain |
d--------- | q3header | 122 | logstatsplain |
d--------- | q3iconview | 126 | logstatsplain |
d--------- | q3listbox | 85 | logstatsplain |
d--------- | q3listview | 126 | logstatsplain |
d--------- | q3listviewitemiterator | 150 | logstatsplain |
d--------- | q3mainwindow | 130 | logstatsplain |
d--------- | q3popupmenu | 128 | logstatsplain |
d--------- | q3process | 215 | logstatsplain |
d--------- | q3progressbar | 132 | logstatsplain |
d--------- | q3progressdialog | 138 | logstatsplain |
d--------- | q3ptrlist | 124 | logstatsplain |
d--------- | q3richtext | 126 | logstatsplain |
d--------- | q3scrollview | 126 | logstatsplain |
d--------- | q3semaphore | 128 | logstatsplain |
d--------- | q3serversocket | 134 | logstatsplain |
d--------- | q3socket | 121 | logstatsplain |
d--------- | q3socketdevice | 134 | logstatsplain |
d--------- | q3sqlcursor | 128 | logstatsplain |
d--------- | q3sqlselectcursor | 102 | logstatsplain |
d--------- | q3stylesheet | 130 | logstatsplain |
d--------- | q3tabdialog | 128 | logstatsplain |
d--------- | q3table | 120 | logstatsplain |
d--------- | q3textbrowser | 171 | logstatsplain |
d--------- | q3textedit | 126 | logstatsplain |
d--------- | q3textstream | 130 | logstatsplain |
d--------- | q3timeedit | 126 | logstatsplain |
d--------- | q3toolbar | 124 | logstatsplain |
d--------- | q3uridrag | 86 | logstatsplain |
d--------- | q3urloperator | 275 | logstatsplain |
d--------- | q3valuelist | 128 | logstatsplain |
d--------- | q3valuevector | 132 | logstatsplain |
d--------- | q3widgetstack | 94 | logstatsplain |
d--------- | q_func_info | 128 | logstatsplain |
d--------- | qabstractbutton | 136 | logstatsplain |
d--------- | qabstractitemmodel | 142 | logstatsplain |
d--------- | qabstractitemview | 140 | logstatsplain |
d--------- | qabstractmessagehandler | 152 | logstatsplain |
d--------- | qabstractnetworkcache | 180 | logstatsplain |
d--------- | qabstractprintdialog | 146 | logstatsplain |
d--------- | qabstractproxymodel | 144 | logstatsplain |
d--------- | qabstractscrollarea | 144 | logstatsplain |
d--------- | qabstractslider | 136 | logstatsplain |
d--------- | qabstractsocket | 136 | logstatsplain |
d--------- | qabstractspinbox | 138 | logstatsplain |
d--------- | qabstracttextdocumentlayout | 160 | logstatsplain |
d--------- | qabstracturiresolver | 191 | logstatsplain |
d--------- | qabstractvideobuffer | 108 | logstatsplain |
d--------- | qabstractvideosurface | 110 | logstatsplain |
d--------- | qabstractxmlforwarditerator | 160 | logstatsplain |
d--------- | qabstractxmlnodemodel | 313 | logstatsplain |
d--------- | qabstractxmlreceiver | 199 | logstatsplain |
d--------- | qaccessibility | 134 | logstatsplain |
d--------- | qaccessibility_mac | 694 | logstatsplain |
d--------- | qaction | 120 | logstatsplain |
d--------- | qactiongroup | 130 | logstatsplain |
d--------- | qalgorithms | 128 | logstatsplain |
d--------- | qanimationgroup | 98 | logstatsplain |
d--------- | qapplication | 312 | logstatsplain |
d--------- | qapplicationargumentparser | 158 | logstatsplain |
d--------- | qatomicint | 126 | logstatsplain |
d--------- | qatomicpointer | 134 | logstatsplain |
d--------- | qaudiodeviceinfo | 100 | logstatsplain |
d--------- | qaudioformat | 92 | logstatsplain |
d--------- | qaudioinput | 90 | logstatsplain |
d--------- | qaudiooutput | 125 | logstatsplain |
d--------- | qautoptr | 122 | logstatsplain |
d--------- | qbitarray | 124 | logstatsplain |
d--------- | qboxlayout | 126 | logstatsplain |
d--------- | qbrush | 118 | logstatsplain |
d--------- | qbuffer | 120 | logstatsplain |
d--------- | qbuttongroup | 130 | logstatsplain |
d--------- | qbytearray | 207 | logstatsplain |
d--------- | qbytearraymatcher | 102 | logstatsplain |
d--------- | qcache | 118 | logstatsplain |
d--------- | qcalendarwidget | 136 | logstatsplain |
d--------- | qchar | 165 | logstatsplain |
d--------- | qcheckbox | 124 | logstatsplain |
d--------- | qclipboard | 223 | logstatsplain |
d--------- | qcolor | 118 | logstatsplain |
d--------- | qcolordialog | 130 | logstatsplain |
d--------- | qcolumnview | 128 | logstatsplain |
d--------- | qcombobox | 124 | logstatsplain |
d--------- | qcommandlinkbutton | 142 | logstatsplain |
d--------- | qcompleter | 126 | logstatsplain |
d--------- | qcomplextext | 177 | logstatsplain |
d--------- | qcontiguouscache | 100 | logstatsplain |
d--------- | qcopchannel | 194 | logstatsplain |
d--------- | qcoreapplication | 138 | logstatsplain |
d--------- | qcryptographichash | 142 | logstatsplain |
d--------- | qcssparser | 161 | logstatsplain |
d--------- | qdatastream | 251 | logstatsplain |
d--------- | qdatawidgetmapper | 140 | logstatsplain |
d--------- | qdate | 116 | logstatsplain |
d--------- | qdatetime | 124 | logstatsplain |
d--------- | qdatetimeedit | 132 | logstatsplain |
d--------- | qdbusabstractadaptor | 146 | logstatsplain |
d--------- | qdbusabstractinterface | 325 | logstatsplain |
d--------- | qdbusconnection | 136 | logstatsplain |
d--------- | qdbuscontext | 130 | logstatsplain |
d--------- | qdbusinterface | 134 | logstatsplain |
d--------- | qdbuslocalcalls | 136 | logstatsplain |
d--------- | qdbusmarshall | 268 | logstatsplain |
d--------- | qdbusmetaobject | 136 | logstatsplain |
d--------- | qdbusmetatype | 132 | logstatsplain |
d--------- | qdbuspendingcall | 138 | logstatsplain |
d--------- | qdbuspendingreply | 140 | logstatsplain |
d--------- | qdbusperformance | 244 | logstatsplain |
d--------- | qdbusreply | 126 | logstatsplain |
d--------- | qdbusserver | 166 | logstatsplain |
d--------- | qdbusservicewatcher | 106 | logstatsplain |
d--------- | qdbusthreading | 134 | logstatsplain |
d--------- | qdbusxmlparser | 134 | logstatsplain |
d--------- | qdebug | 118 | logstatsplain |
d--------- | qdesktopservices | 138 | logstatsplain |
d--------- | qdesktopwidget | 134 | logstatsplain |
d--------- | qdial | 116 | logstatsplain |
d--------- | qdialog | 120 | logstatsplain |
d--------- | qdialogbuttonbox | 138 | logstatsplain |
d--------- | qdir | 359 | logstatsplain |
d--------- | qdirectpainter | 208 | logstatsplain |
d--------- | qdiriterator | 280 | logstatsplain |
d--------- | qdirmodel | 189 | logstatsplain |
d--------- | qdockwidget | 128 | logstatsplain |
d--------- | qdom | 277 | logstatsplain |
d--------- | qdoublespinbox | 134 | logstatsplain |
d--------- | qdoublevalidator | 138 | logstatsplain |
d--------- | qdrag | 116 | logstatsplain |
d--------- | qeasingcurve | 92 | logstatsplain |
d--------- | qerrormessage | 132 | logstatsplain |
d--------- | qevent | 118 | logstatsplain |
d--------- | qeventloop | 126 | logstatsplain |
d--------- | qexplicitlyshareddatapointer | 162 | logstatsplain |
d--------- | qfile | 716 | logstatsplain |
d--------- | qfiledialog | 128 | logstatsplain |
d--------- | qfiledialog2 | 92 | logstatsplain |
d--------- | qfileiconprovider | 140 | logstatsplain |
d--------- | qfileinfo | 201 | logstatsplain |
d--------- | qfilesystemmodel | 138 | logstatsplain |
d--------- | qfilesystemwatcher | 142 | logstatsplain |
d--------- | qflags | 118 | logstatsplain |
d--------- | qfocusevent | 128 | logstatsplain |
d--------- | qfocusframe | 128 | logstatsplain |
d--------- | qfont | 116 | logstatsplain |
d--------- | qfontcombobox | 132 | logstatsplain |
d--------- | qfontdatabase | 172 | logstatsplain |
d--------- | qfontdialog | 186 | logstatsplain |
d--------- | qfontmetrics | 130 | logstatsplain |
d--------- | qformlayout | 128 | logstatsplain |
d--------- | qftp | 195 | logstatsplain |
d--------- | qfuture | 162 | logstatsplain |
d--------- | qfuturewatcher | 134 | logstatsplain |
d--------- | qgetputenv | 126 | logstatsplain |
d--------- | qgl | 147 | logstatsplain |
d--------- | qglobal | 120 | logstatsplain |
d--------- | qgraphicsanchorlayout | 110 | logstatsplain |
d--------- | qgraphicsanchorlayout1 | 112 | logstatsplain |
d--------- | qgraphicseffect | 98 | logstatsplain |
d--------- | qgraphicseffectsource | 110 | logstatsplain |
d--------- | qgraphicsgridlayout | 144 | logstatsplain |
d--------- | qgraphicsitem | 188 | logstatsplain |
d--------- | qgraphicsitemanimation | 150 | logstatsplain |
d--------- | qgraphicslayout | 136 | logstatsplain |
d--------- | qgraphicslayoutitem | 144 | logstatsplain |
d--------- | qgraphicslinearlayout | 148 | logstatsplain |
d--------- | qgraphicsobject | 98 | logstatsplain |
d--------- | qgraphicspixmapitem | 144 | logstatsplain |
d--------- | qgraphicspolygonitem | 146 | logstatsplain |
d--------- | qgraphicsproxywidget | 146 | logstatsplain |
d--------- | qgraphicsscene | 307 | logstatsplain |
d--------- | qgraphicssceneindex | 106 | logstatsplain |
d--------- | qgraphicstransform | 104 | logstatsplain |
d--------- | qgraphicsview | 183 | logstatsplain |
d--------- | qgraphicswidget | 136 | logstatsplain |
d--------- | qgridlayout | 169 | logstatsplain |
d--------- | qgroupbox | 124 | logstatsplain |
d--------- | qguard | 80 | logstatsplain |
d--------- | qguivariant | 128 | logstatsplain |
d--------- | qhash | 116 | logstatsplain |
d--------- | qheaderview | 128 | logstatsplain |
d--------- | qhelpcontentmodel | 224 | logstatsplain |
d--------- | qhelpenginecore | 218 | logstatsplain |
d--------- | qhelpgenerator | 215 | logstatsplain |
d--------- | qhelpindexmodel | 218 | logstatsplain |
d--------- | qhelpprojectdata | 221 | logstatsplain |
d--------- | qhostaddress | 130 | logstatsplain |
d--------- | qhostinfo | 124 | logstatsplain |
d--------- | qhttp | 311 | logstatsplain |
d--------- | qhttpnetworkconnection | 150 | logstatsplain |
d--------- | qhttpnetworkreply | 140 | logstatsplain |
d--------- | qhttpsocketengine | 140 | logstatsplain |
d--------- | qicoimageformat | 168 | logstatsplain |
d--------- | qicon | 410 | logstatsplain |
d--------- | qimage | 151 | logstatsplain |
d--------- | qimageiohandler | 136 | logstatsplain |
d--------- | qimagereader | 242 | logstatsplain |
d--------- | qimagewriter | 163 | logstatsplain |
d--------- | qinputcontext | 94 | logstatsplain |
d--------- | qinputdialog | 130 | logstatsplain |
d--------- | qintvalidator | 132 | logstatsplain |
d--------- | qiodevice | 124 | logstatsplain |
d--------- | qitemdelegate | 132 | logstatsplain |
d--------- | qitemeditorfactory | 142 | logstatsplain |
d--------- | qitemmodel | 204 | logstatsplain |
d--------- | qitemselectionmodel | 144 | logstatsplain |
d--------- | qitemview | 167 | logstatsplain |
d--------- | qkeysequence | 286 | logstatsplain |
d--------- | qlabel | 225 | logstatsplain |
d--------- | qlayout | 155 | logstatsplain |
d--------- | qlcdnumber | 126 | logstatsplain |
d--------- | qlibrary | 252 | logstatsplain |
d--------- | qline | 116 | logstatsplain |
d--------- | qlineedit | 159 | logstatsplain |
d--------- | qlist | 116 | logstatsplain |
d--------- | qlistview | 124 | logstatsplain |
d--------- | qlistwidget | 128 | logstatsplain |
d--------- | qlocale | 190 | logstatsplain |
d--------- | qlocalsocket | 228 | logstatsplain |
d--------- | qmacstyle | 124 | logstatsplain |
d--------- | qmainwindow | 128 | logstatsplain |
d--------- | qmake | 237 | logstatsplain |
d--------- | qmap | 114 | logstatsplain |
d--------- | qmargins | 84 | logstatsplain |
d--------- | qmath | 78 | logstatsplain |
d--------- | qmatrixnxn | 88 | logstatsplain |
d--------- | qmdiarea | 122 | logstatsplain |
d--------- | qmdisubwindow | 132 | logstatsplain |
d--------- | qmenu | 116 | logstatsplain |
d--------- | qmenubar | 122 | logstatsplain |
d--------- | qmessagebox | 128 | logstatsplain |
d--------- | qmetaobject | 128 | logstatsplain |
d--------- | qmetatype | 124 | logstatsplain |
d--------- | qmouseevent | 128 | logstatsplain |
d--------- | qmouseevent_modal | 140 | logstatsplain |
d--------- | qmovie | 155 | logstatsplain |
d--------- | qmultiscreen | 130 | logstatsplain |
d--------- | qmutex | 118 | logstatsplain |
d--------- | qmutexlocker | 130 | logstatsplain |
d--------- | qnativesocketengine | 189 | logstatsplain |
d--------- | qnetworkaccessmanager_and_qprogressdialog | 150 | logstatsplain |
d--------- | qnetworkaddressentry | 146 | logstatsplain |
d--------- | qnetworkcachemetadata | 148 | logstatsplain |
d--------- | qnetworkcookie | 134 | logstatsplain |
d--------- | qnetworkcookiejar | 140 | logstatsplain |
d--------- | qnetworkdiskcache | 140 | logstatsplain |
d--------- | qnetworkinterface | 140 | logstatsplain |
d--------- | qnetworkproxy | 132 | logstatsplain |
d--------- | qnetworkreply | 456 | logstatsplain |
d--------- | qnetworkrequest | 136 | logstatsplain |
d--------- | qnumeric | 122 | logstatsplain |
d--------- | qobject | 284 | logstatsplain |
d--------- | qobjectperformance | 142 | logstatsplain |
d--------- | qobjectrace | 128 | logstatsplain |
d--------- | qpaintengine | 130 | logstatsplain |
d--------- | qpainter | 369 | logstatsplain |
d--------- | qpainterpath | 130 | logstatsplain |
d--------- | qpainterpathstroker | 144 | logstatsplain |
d--------- | qpalette | 122 | logstatsplain |
d--------- | qparallelanimationgroup | 114 | logstatsplain |
d--------- | qpathclipper | 202 | logstatsplain |
d--------- | qpauseanimation | 98 | logstatsplain |
d--------- | qpen | 114 | logstatsplain |
d--------- | qpicture | 122 | logstatsplain |
d--------- | qpixmap | 280 | logstatsplain |
d--------- | qpixmapcache | 130 | logstatsplain |
d--------- | qpixmapfilter | 131 | logstatsplain |
d--------- | qplaintextedit | 134 | logstatsplain |
d--------- | qplugin | 241 | logstatsplain |
d--------- | qpluginloader | 267 | logstatsplain |
d--------- | qpoint | 118 | logstatsplain |
d--------- | qpointer | 122 | logstatsplain |
d--------- | qpolygon | 122 | logstatsplain |
d--------- | qprinter | 122 | logstatsplain |
d--------- | qprinterinfo | 130 | logstatsplain |
d--------- | qprocess | 1029 | logstatsplain |
d--------- | qprocessenvironment | 106 | logstatsplain |
d--------- | qprogressbar | 130 | logstatsplain |
d--------- | qprogressdialog | 136 | logstatsplain |
d--------- | qpropertyanimation | 104 | logstatsplain |
d--------- | qpushbutton | 163 | logstatsplain |
d--------- | qquaternion | 90 | logstatsplain |
d--------- | qqueue | 118 | logstatsplain |
d--------- | qradiobutton | 130 | logstatsplain |
d--------- | qrand | 116 | logstatsplain |
d--------- | qreadlocker | 128 | logstatsplain |
d--------- | qreadwritelock | 134 | logstatsplain |
d--------- | qrect | 116 | logstatsplain |
d--------- | qregexp | 120 | logstatsplain |
d--------- | qregexpvalidator | 138 | logstatsplain |
d--------- | qregion | 120 | logstatsplain |
d--------- | qresourceengine | 253 | logstatsplain |
d--------- | qringbuffer | 90 | logstatsplain |
d--------- | qs60mainapplication | 106 | logstatsplain |
d--------- | qscopedpointer | 134 | logstatsplain |
d--------- | qscriptable | 128 | logstatsplain |
d--------- | qscriptclass | 130 | logstatsplain |
d--------- | qscriptcontext | 134 | logstatsplain |
d--------- | qscriptcontextinfo | 142 | logstatsplain |
d--------- | qscriptengine | 165 | logstatsplain |
d--------- | qscriptengineagent | 142 | logstatsplain |
d--------- | qscriptenginedebugger | 148 | logstatsplain |
d--------- | qscriptextqobject | 140 | logstatsplain |
d--------- | qscriptjstestsuite | 174 | logstatsplain |
d--------- | qscriptstring | 132 | logstatsplain |
d--------- | qscriptv8testsuite | 136 | logstatsplain |
d--------- | qscriptvalue | 268 | logstatsplain |
d--------- | qscriptvalueiterator | 146 | logstatsplain |
d--------- | qscrollarea | 128 | logstatsplain |
d--------- | qscrollbar | 126 | logstatsplain |
d--------- | qsemaphore | 126 | logstatsplain |
d--------- | qsequentialanimationgroup | 118 | logstatsplain |
d--------- | qset | 114 | logstatsplain |
d--------- | qsettings | 431 | logstatsplain |
d--------- | qsharedmemory | 264 | logstatsplain |
d--------- | qsharedpointer | 485 | logstatsplain |
d--------- | qsharedpointer_and_qwidget | 120 | logstatsplain |
d--------- | qshortcut | 124 | logstatsplain |
d--------- | qsidebar | 122 | logstatsplain |
d--------- | qsignalmapper | 132 | logstatsplain |
d--------- | qsignalspy | 126 | logstatsplain |
d--------- | qsimplexmlnodemodel | 193 | logstatsplain |
d--------- | qsize | 116 | logstatsplain |
d--------- | qsizef | 118 | logstatsplain |
d--------- | qsizegrip | 124 | logstatsplain |
d--------- | qslider | 120 | logstatsplain |
d--------- | qsocketnotifier | 136 | logstatsplain |
d--------- | qsocks5socketengine | 144 | logstatsplain |
d--------- | qsoftkeymanager | 98 | logstatsplain |
d--------- | qsortfilterproxymodel | 148 | logstatsplain |
d--------- | qsound | 151 | logstatsplain |
d--------- | qsourcelocation | 136 | logstatsplain |
d--------- | qspinbox | 122 | logstatsplain |
d--------- | qsplitter | 206 | logstatsplain |
d--------- | qsql | 114 | logstatsplain |
d--------- | qsqldatabase | 208 | logstatsplain |
d--------- | qsqldriver | 88 | logstatsplain |
d--------- | qsqlerror | 124 | logstatsplain |
d--------- | qsqlfield | 124 | logstatsplain |
d--------- | qsqlquery | 124 | logstatsplain |
d--------- | qsqlquerymodel | 134 | logstatsplain |
d--------- | qsqlrecord | 126 | logstatsplain |
d--------- | qsqlrelationaltablemodel | 154 | logstatsplain |
d--------- | qsqltablemodel | 134 | logstatsplain |
d--------- | qsqlthread | 126 | logstatsplain |
d--------- | qsslcertificate | 219 | logstatsplain |
d--------- | qsslcipher | 126 | logstatsplain |
d--------- | qsslerror | 124 | logstatsplain |
d--------- | qsslkey | 151 | logstatsplain |
d--------- | qsslsocket | 196 | logstatsplain |
d--------- | qstackedlayout | 134 | logstatsplain |
d--------- | qstackedwidget | 134 | logstatsplain |
d--------- | qstandarditem | 132 | logstatsplain |
d--------- | qstandarditemmodel | 142 | logstatsplain |
d--------- | qstate | 80 | logstatsplain |
d--------- | qstatemachine | 94 | logstatsplain |
d--------- | qstatusbar | 126 | logstatsplain |
d--------- | qstl | 114 | logstatsplain |
d--------- | qstring | 161 | logstatsplain |
d--------- | qstringbuilder1 | 143 | logstatsplain |
d--------- | qstringbuilder2 | 98 | logstatsplain |
d--------- | qstringbuilder3 | 98 | logstatsplain |
d--------- | qstringbuilder4 | 98 | logstatsplain |
d--------- | qstringlist | 128 | logstatsplain |
d--------- | qstringlistmodel | 182 | logstatsplain |
d--------- | qstringmatcher | 134 | logstatsplain |
d--------- | qstyle | 193 | logstatsplain |
d--------- | qstyleoption | 130 | logstatsplain |
d--------- | qstylesheetstyle | 212 | logstatsplain |
d--------- | qsvgdevice | 126 | logstatsplain |
d--------- | qsvggenerator | 172 | logstatsplain |
d--------- | qsvgrenderer | 326 | logstatsplain |
d--------- | qsyntaxhighlighter | 142 | logstatsplain |
d--------- | qsystemsemaphore | 206 | logstatsplain |
d--------- | qsystemtrayicon | 168 | logstatsplain |
d--------- | qtabbar | 120 | logstatsplain |
d--------- | qtableview | 126 | logstatsplain |
d--------- | qtablewidget | 130 |
const qreal pixelSize = ti.fontEngine->fontDef.pixelSize;
if (pixelSize * pixelSize * qAbs(det) >= 64 * 64 || det < 0.25f || det > 4.f)
drawCached = false;
QFontEngineGlyphCache::Type glyphType = ti.fontEngine->glyphFormat >= 0
? QFontEngineGlyphCache::Type(ti.fontEngine->glyphFormat)
: d->glyphCacheType;
if (glyphType == QFontEngineGlyphCache::Raster_RGBMask) {
if (d->device->alphaRequested() || txtype > QTransform::TxTranslate
|| (state()->composition_mode != QPainter::CompositionMode_Source
&& state()->composition_mode != QPainter::CompositionMode_SourceOver))
{
glyphType = QFontEngineGlyphCache::Raster_A8;
}
}
if (drawCached) {
QVarLengthArray<QFixedPoint> positions;
QVarLengthArray<glyph_t> glyphs;
QTransform matrix = QTransform::fromTranslate(p.x(), p.y());
ti.fontEngine->getGlyphPositions(ti.glyphs, matrix, ti.flags, glyphs, positions);
{
QStaticTextItem staticTextItem;
staticTextItem.chars = const_cast<QChar *>(ti.chars);
staticTextItem.fontEngine = ti.fontEngine;
staticTextItem.glyphs = glyphs.data();
staticTextItem.numChars = ti.num_chars;
staticTextItem.numGlyphs = glyphs.size();
staticTextItem.glyphPositions = positions.data();
d->drawCachedGlyphs(glyphType, &staticTextItem);
}
return;
}
QPaintEngineEx::drawTextItem(p, ti);
}
namespace {
class QOpenGLStaticTextUserData: public QStaticTextUserData
{
public:
QOpenGLStaticTextUserData()
: QStaticTextUserData(OpenGLUserData)
{
}
~QOpenGLStaticTextUserData()
{
}
QGL2PEXVertexArray vertexCoordinateArray;
QGL2PEXVertexArray textureCoordinateArray;
};
}
// #define QT_OPENGL_DRAWCACHEDGLYPHS_INDEX_ARRAY_VBO
void QGL2PaintEngineExPrivate::drawCachedGlyphs(QFontEngineGlyphCache::Type glyphType,
QStaticTextItem *staticTextItem)
{
Q_Q(QGL2PaintEngineEx);
QOpenGL2PaintEngineState *s = q->state();
QGLTextureGlyphCache *cache =
(QGLTextureGlyphCache *) staticTextItem->fontEngine->glyphCache(ctx, glyphType, QTransform());
if (!cache || cache->cacheType() != glyphType) {
cache = new QGLTextureGlyphCache(ctx, glyphType, QTransform());
staticTextItem->fontEngine->setGlyphCache(ctx, cache);
}
cache->setPaintEnginePrivate(this);
cache->populate(staticTextItem->fontEngine, staticTextItem->numGlyphs, staticTextItem->glyphs,
staticTextItem->glyphPositions);
if (cache->width() == 0 || cache->height() == 0)
return;
transferMode(TextDrawingMode);
int margin = cache->glyphMargin();
GLfloat dx = 1.0 / cache->width();
GLfloat dy = 1.0 / cache->height();
bool recreateVertexArrays = false;
if (staticTextItem->userDataNeedsUpdate)
recreateVertexArrays = true;
else if (staticTextItem->userData == 0)
recreateVertexArrays = true;
else if (staticTextItem->userData->type != QStaticTextUserData::OpenGLUserData)
recreateVertexArrays = true;
// Use global arrays by default
QGL2PEXVertexArray *vertexCoordinates = &vertexCoordinateArray;
QGL2PEXVertexArray *textureCoordinates = &textureCoordinateArray;
if (staticTextItem->useBackendOptimizations) {
QOpenGLStaticTextUserData *userData = 0;
if (staticTextItem->userData == 0
|| staticTextItem->userData->type != QStaticTextUserData::OpenGLUserData) {
userData = new QOpenGLStaticTextUserData();
staticTextItem->setUserData(userData);
} else {
userData = static_cast<QOpenGLStaticTextUserData*>(staticTextItem->userData);
}
// Use cache if backend optimizations is turned on
vertexCoordinates = &userData->vertexCoordinateArray;
textureCoordinates = &userData->textureCoordinateArray;
}
if (recreateVertexArrays) {
vertexCoordinates->clear();
textureCoordinates->clear();
for (int i=0; i<staticTextItem->numGlyphs; ++i) {
const QTextureGlyphCache::Coord &c = cache->coords.value(staticTextItem->glyphs[i]);
int x = staticTextItem->glyphPositions[i].x.toInt() + c.baseLineX - margin;
int y = staticTextItem->glyphPositions[i].y.toInt() - c.baseLineY - margin;
vertexCoordinates->addQuad(QRectF(x, y, c.w, c.h));
textureCoordinates->addQuad(QRectF(c.x*dx, c.y*dy, c.w * dx, c.h * dy));
}
staticTextItem->userDataNeedsUpdate = false;
}
if (elementIndices.size() < staticTextItem->numGlyphs*6) {
Q_ASSERT(elementIndices.size() % 6 == 0);
int j = elementIndices.size() / 6 * 4;
while (j < staticTextItem->numGlyphs*4) {
elementIndices.append(j + 0);
elementIndices.append(j + 0);
elementIndices.append(j + 1);
elementIndices.append(j + 2);
elementIndices.append(j + 3);
elementIndices.append(j + 3);
j += 4;
}
#if defined(QT_OPENGL_DRAWCACHEDGLYPHS_INDEX_ARRAY_VBO)
if (elementIndicesVBOId == 0)
glGenBuffers(1, &elementIndicesVBOId);
glBindBuffer(GL_ELEMENT_ARRAY_BUFFER, elementIndicesVBOId);
glBufferData(GL_ELEMENT_ARRAY_BUFFER, elementIndices.size() * sizeof(GLushort),
elementIndices.constData(), GL_STATIC_DRAW);
#endif
} else {
#if defined(QT_OPENGL_DRAWCACHEDGLYPHS_INDEX_ARRAY_VBO)
glBindBuffer(GL_ELEMENT_ARRAY_BUFFER, elementIndicesVBOId);
#endif
}
setVertexAttributePointer(QT_VERTEX_COORDS_ATTR, (GLfloat*)vertexCoordinates->data());
setVertexAttributePointer(QT_TEXTURE_COORDS_ATTR, (GLfloat*)textureCoordinates->data());
if (addOffset) {
addOffset = false;
matrixDirty = true;
}
if (!snapToPixelGrid) {
snapToPixelGrid = true;
matrixDirty = true;
}
QBrush pensBrush = q->state()->pen.brush();
setBrush(pensBrush);
if (glyphType == QFontEngineGlyphCache::Raster_RGBMask) {
// Subpixel antialiasing without gamma correction
QPainter::CompositionMode compMode = q->state()->composition_mode;
Q_ASSERT(compMode == QPainter::CompositionMode_Source
|| compMode == QPainter::CompositionMode_SourceOver);
shaderManager->setMaskType(QGLEngineShaderManager::SubPixelMaskPass1);
if (pensBrush.style() == Qt::SolidPattern) {
// Solid patterns can get away with only one pass.
QColor c = pensBrush.color();
qreal oldOpacity = q->state()->opacity;
if (compMode == QPainter::CompositionMode_Source) {
c = qt_premultiplyColor(c, q->state()->opacity);
q->state()->opacity = 1;
opacityUniformDirty = true;
}
compositionModeDirty = false; // I can handle this myself, thank you very much
prepareForDraw(false); // Text always causes src pixels to be transparent
// prepareForDraw() have set the opacity on the current shader, so the opacity state can now be reset.
if (compMode == QPainter::CompositionMode_Source) {
q->state()->opacity = oldOpacity;
opacityUniformDirty = true;
}
glEnable(GL_BLEND);
glBlendFunc(GL_CONSTANT_COLOR, GL_ONE_MINUS_SRC_COLOR);
glBlendColor(c.redF(), c.greenF(), c.blueF(), c.alphaF());
} else {
// Other brush styles need two passes.
qreal oldOpacity = q->state()->opacity;
if (compMode == QPainter::CompositionMode_Source) {
q->state()->opacity = 1;
opacityUniformDirty = true;
pensBrush = Qt::white;
setBrush(pensBrush);
}
compositionModeDirty = false; // I can handle this myself, thank you very much
prepareForDraw(false); // Text always causes src pixels to be transparent
glEnable(GL_BLEND);
glBlendFunc(GL_ZERO, GL_ONE_MINUS_SRC_COLOR);
glActiveTexture(GL_TEXTURE0 + QT_MASK_TEXTURE_UNIT);
glBindTexture(GL_TEXTURE_2D, cache->texture());
updateTextureFilter(GL_TEXTURE_2D, GL_REPEAT, false);
shaderManager->currentProgram()->setUniformValue(location(QGLEngineShaderManager::MaskTexture), QT_MASK_TEXTURE_UNIT);
#if defined(QT_OPENGL_DRAWCACHEDGLYPHS_INDEX_ARRAY_VBO)
glDrawElements(GL_TRIANGLE_STRIP, 6 * staticTextItem->numGlyphs, GL_UNSIGNED_SHORT, 0);
#else
glDrawElements(GL_TRIANGLE_STRIP, 6 * staticTextItem->numGlyphs, GL_UNSIGNED_SHORT, elementIndices.data());
#endif
shaderManager->setMaskType(QGLEngineShaderManager::SubPixelMaskPass2);
if (compMode == QPainter::CompositionMode_Source) {
q->state()->opacity = oldOpacity;
opacityUniformDirty = true;
pensBrush = q->state()->pen.brush();
setBrush(pensBrush);
}
compositionModeDirty = false;
prepareForDraw(false); // Text always causes src pixels to be transparent
glEnable(GL_BLEND);
glBlendFunc(GL_ONE, GL_ONE);
}
compositionModeDirty = true;
} else {
// Greyscale/mono glyphs
shaderManager->setMaskType(QGLEngineShaderManager::PixelMask);
prepareForDraw(false); // Text always causes src pixels to be transparent
}
//### TODO: Gamma correction
glActiveTexture(GL_TEXTURE0 + QT_MASK_TEXTURE_UNIT);
if (lastMaskTextureUsed != cache->texture()) {
glBindTexture(GL_TEXTURE_2D, cache->texture());
lastMaskTextureUsed = cache->texture();
}
updateTextureFilter(GL_TEXTURE_2D, GL_REPEAT, s->matrix.type() > QTransform::TxTranslate);
shaderManager->currentProgram()->setUniformValue(location(QGLEngineShaderManager::MaskTexture), QT_MASK_TEXTURE_UNIT);
#if defined(QT_OPENGL_DRAWCACHEDGLYPHS_INDEX_ARRAY_VBO)
glDrawElements(GL_TRIANGLE_STRIP, 6 * staticTextItem->numGlyphs, GL_UNSIGNED_SHORT, 0);
glBindBuffer(GL_ELEMENT_ARRAY_BUFFER, 0);
#else
glDrawElements(GL_TRIANGLE_STRIP, 6 * staticTextItem->numGlyphs, GL_UNSIGNED_SHORT, elementIndices.data());
#endif
}
void QGL2PaintEngineEx::drawPixmapFragments(const QPainter::PixmapFragment *fragments, int fragmentCount, const QPixmap &pixmap,
QPainter::PixmapFragmentHints hints)
{
Q_D(QGL2PaintEngineEx);
// Use fallback for extended composition modes.
if (state()->composition_mode > QPainter::CompositionMode_Plus) {
QPaintEngineEx::drawPixmapFragments(fragments, fragmentCount, pixmap, hints);
return;
}
ensureActive();
d->drawPixmapFragments(fragments, fragmentCount, pixmap, hints);
}
void QGL2PaintEngineExPrivate::drawPixmapFragments(const QPainter::PixmapFragment *fragments,
int fragmentCount, const QPixmap &pixmap,
QPainter::PixmapFragmentHints hints)
{
GLfloat dx = 1.0f / pixmap.size().width();
GLfloat dy = 1.0f / pixmap.size().height();
vertexCoordinateArray.clear();
textureCoordinateArray.clear();
opacityArray.reset();
if (addOffset) {
addOffset = false;
matrixDirty = true;
}
if (snapToPixelGrid) {
snapToPixelGrid = false;
matrixDirty = true;
}
bool allOpaque = true;
for (int i = 0; i < fragmentCount; ++i) {
qreal s = 0;
qreal c = 1;
if (fragments[i].rotation != 0) {
s = qFastSin(fragments[i].rotation * Q_PI / 180);
c = qFastCos(fragments[i].rotation * Q_PI / 180);
}
qreal right = 0.5 * fragments[i].scaleX * fragments[i].width;
qreal bottom = 0.5 * fragments[i].scaleY * fragments[i].height;
QGLPoint bottomRight(right * c - bottom * s, right * s + bottom * c);
QGLPoint bottomLeft(-right * c - bottom * s, -right * s + bottom * c);
vertexCoordinateArray.addVertex(bottomRight.x + fragments[i].x, bottomRight.y + fragments[i].y);
vertexCoordinateArray.addVertex(-bottomLeft.x + fragments[i].x, -bottomLeft.y + fragments[i].y);
vertexCoordinateArray.addVertex(-bottomRight.x + fragments[i].x, -bottomRight.y + fragments[i].y);
vertexCoordinateArray.addVertex(-bottomRight.x + fragments[i].x, -bottomRight.y + fragments[i].y);
vertexCoordinateArray.addVertex(bottomLeft.x + fragments[i].x, bottomLeft.y + fragments[i].y);
vertexCoordinateArray.addVertex(bottomRight.x + fragments[i].x, bottomRight.y + fragments[i].y);
QGLRect src(fragments[i].sourceLeft * dx, fragments[i].sourceTop * dy,
(fragments[i].sourceLeft + fragments[i].width) * dx,
(fragments[i].sourceTop + fragments[i].height) * dy);
textureCoordinateArray.addVertex(src.right, src.bottom);
textureCoordinateArray.addVertex(src.right, src.top);
textureCoordinateArray.addVertex(src.left, src.top);
textureCoordinateArray.addVertex(src.left, src.top);
textureCoordinateArray.addVertex(src.left, src.bottom);
textureCoordinateArray.addVertex(src.right, src.bottom);
qreal opacity = fragments[i].opacity * q->state()->opacity;
opacityArray << opacity << opacity << opacity << opacity << opacity << opacity;
allOpaque &= (opacity >= 0.99f);
}
glActiveTexture(GL_TEXTURE0 + QT_IMAGE_TEXTURE_UNIT);
QGLTexture *texture = ctx->d_func()->bindTexture(pixmap, GL_TEXTURE_2D, GL_RGBA,
QGLContext::InternalBindOption
| QGLContext::CanFlipNativePixmapBindOption);
if (texture->options & QGLContext::InvertedYBindOption) {
// Flip texture y-coordinate.
QGLPoint *data = textureCoordinateArray.data();
for (int i = 0; i < 6 * fragmentCount; ++i)
data[i].y = 1 - data[i].y;
}
transferMode(ImageArrayDrawingMode);
bool isBitmap = pixmap.isQBitmap();
bool isOpaque = !isBitmap && (!pixmap.hasAlphaChannel() || (hints & QPainter::OpaqueHint)) && allOpaque;
updateTextureFilter(GL_TEXTURE_2D, GL_CLAMP_TO_EDGE,
q->state()->renderHints & QPainter::SmoothPixmapTransform, texture->id);
// Setup for texture drawing
currentBrush = noBrush;
shaderManager->setSrcPixelType(isBitmap ? QGLEngineShaderManager::PatternSrc
: QGLEngineShaderManager::ImageSrc);
if (prepareForDraw(isOpaque))
shaderManager->currentProgram()->setUniformValue(location(QGLEngineShaderManager::ImageTexture), QT_IMAGE_TEXTURE_UNIT);
if (isBitmap) {
QColor col = qt_premultiplyColor(q->state()->pen.color(), (GLfloat)q->state()->opacity);
shaderManager->currentProgram()->setUniformValue(location(QGLEngineShaderManager::PatternColor), col);
}
glDrawArrays(GL_TRIANGLES, 0, 6 * fragmentCount);
}
bool QGL2PaintEngineEx::begin(QPaintDevice *pdev)
{
Q_D(QGL2PaintEngineEx);
// qDebug("QGL2PaintEngineEx::begin()");
if (pdev->devType() == QInternal::OpenGL)
d->device = static_cast<QGLPaintDevice*>(pdev);
else
d->device = QGLPaintDevice::getDevice(pdev);
if (!d->device)
return false;
d->ctx = d->device->context();
d->ctx->d_ptr->active_engine = this;
const QSize sz = d->device->size();
d->width = sz.width();
d->height = sz.height();
d->mode = BrushDrawingMode;
d->brushTextureDirty = true;
d->brushUniformsDirty = true;
d->matrixUniformDirty = true;
d->matrixDirty = true;
d->compositionModeDirty = true;
d->opacityUniformDirty = true;
d->needsSync = true;
d->useSystemClip = !systemClip().isEmpty();
d->currentBrush = QBrush();
d->dirtyStencilRegion = QRect(0, 0, d->width, d->height);
d->stencilClean = true;
// Calling begin paint should make the correct context current. So, any
// code which calls into GL or otherwise needs a current context *must*
// go after beginPaint:
d->device->beginPaint();
#if !defined(QT_OPENGL_ES_2)
bool success = qt_resolve_version_2_0_functions(d->ctx)
&& qt_resolve_buffer_extensions(d->ctx);
Q_ASSERT(success);
Q_UNUSED(success);
#endif
d->shaderManager = new QGLEngineShaderManager(d->ctx);
glDisable(GL_STENCIL_TEST);
glDisable(GL_DEPTH_TEST);
glDisable(GL_SCISSOR_TEST);
#if !defined(QT_OPENGL_ES_2)
glDisable(GL_MULTISAMPLE);
#endif
d->glyphCacheType = QFontEngineGlyphCache::Raster_A8;
#if !defined(QT_OPENGL_ES_2)
#if defined(Q_WS_WIN)
if (qt_cleartype_enabled)
#endif
d->glyphCacheType = QFontEngineGlyphCache::Raster_RGBMask;
#endif
#if defined(QT_OPENGL_ES_2)
// OpenGL ES can't switch MSAA off, so if the gl paint device is
// multisampled, it's always multisampled.
d->multisamplingAlwaysEnabled = d->device->format().sampleBuffers();
#else
d->multisamplingAlwaysEnabled = false;
#endif
return true;
}
bool QGL2PaintEngineEx::end()
{
Q_D(QGL2PaintEngineEx);
QGLContext *ctx = d->ctx;
glUseProgram(0);
d->transferMode(BrushDrawingMode);
d->device->endPaint();
#if defined(Q_WS_X11)
// On some (probably all) drivers, deleting an X pixmap which has been bound to a texture
// before calling glFinish/swapBuffers renders garbage. Presumably this is because X deletes
// the pixmap behind the driver's back before it's had a chance to use it. To fix this, we
// reference all QPixmaps which have been bound to stop them being deleted and only deref
// them here, after swapBuffers, where they can be safely deleted.
ctx->d_func()->boundPixmaps.clear();
#endif
d->ctx->d_ptr->active_engine = 0;
d->resetGLState();
delete d->shaderManager;
d->shaderManager = 0;
d->currentBrush = QBrush();
#ifdef QT_OPENGL_CACHE_AS_VBOS
if (!d->unusedVBOSToClean.isEmpty()) {
glDeleteBuffers(d->unusedVBOSToClean.size(), d->unusedVBOSToClean.constData());
d->unusedVBOSToClean.clear();
}
if (!d->unusedIBOSToClean.isEmpty()) {
glDeleteBuffers(d->unusedIBOSToClean.size(), d->unusedIBOSToClean.constData());
d->unusedIBOSToClean.clear();
}
#endif
return false;
}
void QGL2PaintEngineEx::ensureActive()
{
Q_D(QGL2PaintEngineEx);
QGLContext *ctx = d->ctx;
if (isActive() && ctx->d_ptr->active_engine != this) {
ctx->d_ptr->active_engine = this;
d->needsSync = true;
}
d->device->ensureActiveTarget();
if (d->needsSync) {
d->transferMode(BrushDrawingMode);
glViewport(0, 0, d->width, d->height);
d->needsSync = false;
d->lastMaskTextureUsed = 0;
d->shaderManager->setDirty();
d->ctx->d_func()->syncGlState();
for (int i = 0; i < 3; ++i)
d->vertexAttribPointers[i] = (GLfloat*)-1; // Assume the pointers are clobbered
setState(state());
}
}
void QGL2PaintEngineExPrivate::updateClipScissorTest()
{
Q_Q(QGL2PaintEngineEx);
if (q->state()->clipTestEnabled) {
glEnable(GL_STENCIL_TEST);
glStencilFunc(GL_LEQUAL, q->state()->currentClip, ~GL_STENCIL_HIGH_BIT);
} else {
glDisable(GL_STENCIL_TEST);
glStencilFunc(GL_ALWAYS, 0, 0xff);
}
#ifdef QT_GL_NO_SCISSOR_TEST
currentScissorBounds = QRect(0, 0, width, height);
#else
QRect bounds = q->state()->rectangleClip;
if (!q->state()->clipEnabled) {
if (useSystemClip)
bounds = systemClip.boundingRect();
else
bounds = QRect(0, 0, width, height);
} else {
if (useSystemClip)
bounds = bounds.intersected(systemClip.boundingRect());
else
bounds = bounds.intersected(QRect(0, 0, width, height));
}
currentScissorBounds = bounds;
if (bounds == QRect(0, 0, width, height)) {
glDisable(GL_SCISSOR_TEST);
} else {
glEnable(GL_SCISSOR_TEST);
setScissor(bounds);
}
#endif
}
void QGL2PaintEngineExPrivate::setScissor(const QRect &rect)
{
const int left = rect.left();
const int width = rect.width();
const int bottom = height - (rect.top() + rect.height());
const int height = rect.height();
glScissor(left, bottom, width, height);
}
void QGL2PaintEngineEx::clipEnabledChanged()
{
Q_D(QGL2PaintEngineEx);
state()->clipChanged = true;
if (painter()->hasClipping())
d->regenerateClip();
else
d->systemStateChanged();
}
void QGL2PaintEngineExPrivate::clearClip(uint value)
{
dirtyStencilRegion -= currentScissorBounds;
glStencilMask(0xff);
glClearStencil(value);
glClear(GL_STENCIL_BUFFER_BIT);
glStencilMask(0x0);
q->state()->needsClipBufferClear = false;
}
void QGL2PaintEngineExPrivate::writeClip(const QVectorPath &path, uint value)
{
transferMode(BrushDrawingMode);
if (addOffset) {
addOffset = false;
matrixDirty = true;
}
if (snapToPixelGrid) {
snapToPixelGrid = false;
matrixDirty = true;
}
if (matrixDirty)
updateMatrix();
stencilClean = false;
const bool singlePass = !path.hasWindingFill()
&& (((q->state()->currentClip == maxClip - 1) && q->state()->clipTestEnabled)
|| q->state()->needsClipBufferClear);
const uint referenceClipValue = q->state()->needsClipBufferClear ? 1 : q->state()->currentClip;
if (q->state()->needsClipBufferClear)
clearClip(1);
if (path.isEmpty()) {
glEnable(GL_STENCIL_TEST);
glStencilFunc(GL_LEQUAL, value, ~GL_STENCIL_HIGH_BIT);
return;
}
if (q->state()->clipTestEnabled)
glStencilFunc(GL_LEQUAL, q->state()->currentClip, ~GL_STENCIL_HIGH_BIT);
else
glStencilFunc(GL_ALWAYS, 0, 0xff);
vertexCoordinateArray.clear();
vertexCoordinateArray.addPath(path, inverseScale, false);
if (!singlePass)
fillStencilWithVertexArray(vertexCoordinateArray, path.hasWindingFill());
glColorMask(false, false, false, false);
glEnable(GL_STENCIL_TEST);
useSimpleShader();
if (singlePass) {
// Under these conditions we can set the new stencil value in a single
// pass, by using the current value and the "new value" as the toggles
glStencilFunc(GL_LEQUAL, referenceClipValue, ~GL_STENCIL_HIGH_BIT);
glStencilOp(GL_KEEP, GL_INVERT, GL_INVERT);
glStencilMask(value ^ referenceClipValue);
drawVertexArrays(vertexCoordinateArray, GL_TRIANGLE_FAN);
} else {
glStencilOp(GL_KEEP, GL_REPLACE, GL_REPLACE);
glStencilMask(0xff);
if (!q->state()->clipTestEnabled && path.hasWindingFill()) {
// Pass when any clip bit is set, set high bit
glStencilFunc(GL_NOTEQUAL, GL_STENCIL_HIGH_BIT, ~GL_STENCIL_HIGH_BIT);
composite(vertexCoordinateArray.boundingRect());
}
// Pass when high bit is set, replace stencil value with new clip value
glStencilFunc(GL_NOTEQUAL, value, GL_STENCIL_HIGH_BIT);
composite(vertexCoordinateArray.boundingRect());
}
glStencilFunc(GL_LEQUAL, value, ~GL_STENCIL_HIGH_BIT);
glStencilMask(0);
glColorMask(true, true, true, true);
}
void QGL2PaintEngineEx::clip(const QVectorPath &path, Qt::ClipOperation op)
{
// qDebug("QGL2PaintEngineEx::clip()");
Q_D(QGL2PaintEngineEx);
state()->clipChanged = true;
ensureActive();
if (op == Qt::ReplaceClip) {
op = Qt::IntersectClip;
if (d->hasClipOperations()) {
d->systemStateChanged();
state()->canRestoreClip = false;
}
}
#ifndef QT_GL_NO_SCISSOR_TEST
if (!path.isEmpty() && op == Qt::IntersectClip && (path.shape() == QVectorPath::RectangleHint)) {
const QPointF* const points = reinterpret_cast<const QPointF*>(path.points());
QRectF rect(points[0], points[2]);
if (state()->matrix.type() <= QTransform::TxScale) {
state()->rectangleClip = state()->rectangleClip.intersected(state()->matrix.mapRect(rect).toRect());
d->updateClipScissorTest();
return;
}
}
#endif
const QRect pathRect = state()->matrix.mapRect(path.controlPointRect()).toAlignedRect();
switch (op) {
case Qt::NoClip:
if (d->useSystemClip) {
state()->clipTestEnabled = true;
state()->currentClip = 1;
} else {
state()->clipTestEnabled = false;
}
state()->rectangleClip = QRect(0, 0, d->width, d->height);
state()->canRestoreClip = false;
d->updateClipScissorTest();
break;
case Qt::IntersectClip:
state()->rectangleClip = state()->rectangleClip.intersected(pathRect);
d->updateClipScissorTest();
d->resetClipIfNeeded();
++d->maxClip;
d->writeClip(path, d->maxClip);
state()->currentClip = d->maxClip;
state()->clipTestEnabled = true;
break;
case Qt::UniteClip: {
d->resetClipIfNeeded();
++d->maxClip;
if (state()->rectangleClip.isValid()) {
QPainterPath path;
path.addRect(state()->rectangleClip);
// flush the existing clip rectangle to the depth buffer
d->writeClip(qtVectorPathForPath(state()->matrix.inverted().map(path)), d->maxClip);
}
state()->clipTestEnabled = false;
#ifndef QT_GL_NO_SCISSOR_TEST
QRect oldRectangleClip = state()->rectangleClip;
state()->rectangleClip = state()->rectangleClip.united(pathRect);
d->updateClipScissorTest();
QRegion extendRegion = QRegion(state()->rectangleClip) - oldRectangleClip;
if (!extendRegion.isEmpty()) {
QPainterPath extendPath;
extendPath.addRegion(extendRegion);
// first clear the depth buffer in the extended region
d->writeClip(qtVectorPathForPath(state()->matrix.inverted().map(extendPath)), 0);
}
#endif
// now write the clip path
d->writeClip(path, d->maxClip);
state()->canRestoreClip = false;
state()->currentClip = d->maxClip;
state()->clipTestEnabled = true;
break;
}
default:
break;
}
}
void QGL2PaintEngineExPrivate::regenerateClip()
{
systemStateChanged();
replayClipOperations();
}
void QGL2PaintEngineExPrivate::systemStateChanged()
{
Q_Q(QGL2PaintEngineEx);
q->state()->clipChanged = true;
if (systemClip.isEmpty()) {
useSystemClip = false;
} else {
if (q->paintDevice()->devType() == QInternal::Widget && currentClipWidget) {
QWidgetPrivate *widgetPrivate = qt_widget_private(currentClipWidget->window());
useSystemClip = widgetPrivate->extra && widgetPrivate->extra->inRenderWithPainter;
} else {
useSystemClip = true;
}
}
q->state()->clipTestEnabled = false;
q->state()->needsClipBufferClear = true;
q->state()->currentClip = 1;
maxClip = 1;
q->state()->rectangleClip = useSystemClip ? systemClip.boundingRect() : QRect(0, 0, width, height);
updateClipScissorTest();
if (systemClip.rectCount() == 1) {
if (systemClip.boundingRect() == QRect(0, 0, width, height))
useSystemClip = false;
#ifndef QT_GL_NO_SCISSOR_TEST
// scissoring takes care of the system clip
return;
#endif
}
if (useSystemClip) {
clearClip(0);
QPainterPath path;
path.addRegion(systemClip);
q->state()->currentClip = 0;
writeClip(qtVectorPathForPath(q->state()->matrix.inverted().map(path)), 1);
q->state()->currentClip = 1;
q->state()->clipTestEnabled = true;
}
}
void QGL2PaintEngineEx::setState(QPainterState *new_state)
{
// qDebug("QGL2PaintEngineEx::setState()");
Q_D(QGL2PaintEngineEx);
QOpenGL2PaintEngineState *s = static_cast<QOpenGL2PaintEngineState *>(new_state);
QOpenGL2PaintEngineState *old_state = state();
QPaintEngineEx::setState(s);
if (s->isNew) {
// Newly created state object. The call to setState()
// will either be followed by a call to begin(), or we are
// setting the state as part of a save().
s->isNew = false;
return;
}
// Setting the state as part of a restore().
if (old_state == s || old_state->renderHintsChanged)
renderHintsChanged();
if (old_state == s || old_state->matrixChanged)
d->matrixDirty = true;
if (old_state == s || old_state->compositionModeChanged)
d->compositionModeDirty = true;
if (old_state == s || old_state->opacityChanged)
d->opacityUniformDirty = true;
if (old_state == s || old_state->clipChanged) {
if (old_state && old_state != s && old_state->canRestoreClip) {
d->updateClipScissorTest();
glDepthFunc(GL_LEQUAL);
} else {
d->regenerateClip();
}
}
}
QPainterState *QGL2PaintEngineEx::createState(QPainterState *orig) const
{
if (orig)
const_cast<QGL2PaintEngineEx *>(this)->ensureActive();
QOpenGL2PaintEngineState *s;
if (!orig)
s = new QOpenGL2PaintEngineState();
else
s = new QOpenGL2PaintEngineState(*static_cast<QOpenGL2PaintEngineState *>(orig));
s->matrixChanged = false;
s->compositionModeChanged = false;
s->opacityChanged = false;
s->renderHintsChanged = false;
s->clipChanged = false;
return s;
}
QOpenGL2PaintEngineState::QOpenGL2PaintEngineState(QOpenGL2PaintEngineState &other)
: QPainterState(other)
{
isNew = true;
needsClipBufferClear = other.needsClipBufferClear;
clipTestEnabled = other.clipTestEnabled;
currentClip = other.currentClip;
canRestoreClip = other.canRestoreClip;
rectangleClip = other.rectangleClip;
}
QOpenGL2PaintEngineState::QOpenGL2PaintEngineState()
{
isNew = true;
needsClipBufferClear = true;
clipTestEnabled = false;
canRestoreClip = true;
}
QOpenGL2PaintEngineState::~QOpenGL2PaintEngineState()
{
}
QT_END_NAMESPACE
|