AppendixesPART3Third-PartyToolsThisappendixshowsyousomethird-partytools.
AlargecommunityofprojectsisbuiltonandaroundQt,andthetoolsshownherearejustasmallselectionofwhatisavailable.
Thepurposeisnottoshowyouhowtheyareused,buttoshowyouthediversityofavailabletools.
Eachoftheprojectsmentionedcomeswithgooddocumentationandiseasytolearn.
501APPENDIXAQtWidgetsforTechnicalApplications:QwtCategory:WidgetsandclassesWebsite:http://qwt.
sf.
netLicense:QwtLicense—agenerousversionofLGPLQwtisacollectionofclassesandwidgetsforuseintechnicalapplications.
Thewidgetsincludedials,sliders,knobs,plots,scales,andlegends.
Thewidgetsprovidedarewellinte-gratedwithDesignerthroughplugins.
SomesamplescreenshotsofQwtinactioncanbeseeninFigureA-1,whichshowssomeofthedialsthatQwtprovides.
Thesedials,combinedwithwheelsandsliders,makeiteasytospecifyvalues.
However,therealpowerofQwtiswithitsplottingcapabilities.
Youcancreatescatterplots,curveplots,andhistograms—withorwithoutcontourlines.
ThedataforalltheseplotsisservedthroughtheQwtDataclassoritsdescendants.
ByinheritingtheQwtDataclass,youcancalculatethedatatoplotontheflyandthenfeedittotheappropriateplotwidget.
FigureA-1.
WidgetsandplotsfromtheQwtexamplesAPPENDIXATHIRD-PARTYTOOLS502wwWidgetsCategory:WidgetsWebsite:http://www.
wysota.
eu.
org/wwwidgetsLicense:GPLThewwWidgetslibrarycomplementsQtwitharangeofwidgets.
ThesewidgetsfocusontheareasthatQtdoesnotfillfromthestart—color-pickingwidgets,onscreenkeypads,andsuch—butalsooncommoncomposedwidgetssuchasthestartuptipwidget.
ExamplesfromaDesignersessionareshowninFigureA-2.
Thesewidgetssavetimebecausetheydon'thavetobereinventedwitheverynewproject.
ThewwWidgetslibraryisverywellintegratedwiththerestofQt—bothinDesignerandthebuildsystem.
Whenitisinstalled,itaddsitselftotheQtinstallation,soallyouneedtodotouseitisaddCONFIG+=wwwidgetsinyourprojectfile—justassimpleasusingaQtmodule.
FigureA-2.
SomewwWidgetsinaDesignersessionAPPENDIXATHIRD-PARTYTOOLS503QDevelopCategory:DevelopmentenvironmentWebsite:http://www.
qdevelop.
orgLicense:GPLQDevelopisatruecross-platform,integrateddevelopmentenvironmentadaptedforQt.
ItprovidesacommondevelopmentenvironmentacrossallplatformssupportedbyQt.
YoucanseeasamplesessioninFigureA-3.
ThestrengthsofQDevelopincludeitscapabilitytodebugapplicationsusingtheGNUdebugger(gdb),capabilitytohandleQMakeprojects,capabilitytoprovidecodecompletionandlistsofmethodsusingctags,anditsplugin-basedarchitecture.
CautionTousegdbontheWindowsplatform,youmustfirstinstallit(youcanfinddetailsontheQDevelopwebsite).
FigureA-3.
QDevelopinactionAPPENDIXATHIRD-PARTYTOOLS504Thedependencyofctagsforcodecompletionandmethodlistsmeansthattheinterfacecanbeslowbecausectagsisrunasanexternalprocess,andQDevelopwaitsforittocompletebeforethesefeaturesactuallywork.
QDevelopdoeshaveanannoyingbug.
WhenrequestinghelpforamemberfunctionofaQtclass,itfails.
Youmustalwayspositionthecursorovertheactualclassnamewhenlookingforhelp.
WhenQtAssistantislaunchedtoprovidehelp,itlaunchesasaseparateapplication.
QDeveloplaunchesbothDesignerandQtAssistantasexternalapplicationsrunninginparal-lelwiththeQDevelopapplication.
Thisworksgreat,butyouhavetoswitchmanuallybackandforthbetweentheapplications.
EdyukCategory:DevelopmentenvironmentWebsite:http://edyuk.
sf.
netLicense:GPLEdyukisanothercross-platform,integrateddevelopmentenvironmentdesignedforusewithQt.
Edyuk,whichisbuiltaroundperspectivesandplugins,integratesbothDesignerandQtAssistantfully,soyoucanswitchbetweencodeviewandDesignerwithintheEdyukenvi-ronment.
FigureA-4showsscreenshotsthatdisplaythecodeperspective(top)andtheDesignerperspective(bottom).
Theprojectfilesupportisgood,asisthecodeeditor,butopeningprojectscanbescarybecausetheuserinterfacecansometimesbeunresponsivewhileloading.
However,thedevel-opmentpaceishigh(atthetimeofwritingthisbook),sothissituationwillprobablyhaveimprovedbythetimethatyoureadthis.
NoteDifferentpanelsthatmakeupeachperspectivecanbeshownorhiddenbyusingbuttonslocatedatthebottom-rightcorner.
Thesebuttonsarenotalwayseasytofind.
APPENDIXATHIRD-PARTYTOOLS505FigureA-4.
TheEdyukeditorinactionAPPENDIXATHIRD-PARTYTOOLS506Containers,Types,andMacrosQtprovidesarangeofmacros,types,andcontainersformakingyourlifeasadevelopereasier.
Youcanusethischapterasareferencewhencomparingandusingthesefeatures.
ContainersThereareanumberofcontainersavailable,whichIhavesplitintothreegroups:sequences,specializedcontainers,andassociativecontainers.
Sequencesarejustplainlistsforkeepingobjects.
Specializedcontainersareoptimizedforkeepingacertaincontenttypeorforaspe-cificusagescenario.
Associativecontainersareusedforassociatingeachdataitemtoakeyvalue.
Eachofthefollowingsectionsconsistsoftheprosandconsofeachtype—prosaremarkedwithplussigns(+);consaremarkedwithminussigns(–).
SequencesQList+Quickinsertionsatthestart+Quickinsertionsattheend+Quickindexedaccess+Quickiteratoraccess–SlowinsertionsinthemiddleoflargelistsQLinkedList+Quickinsertionsatthestart+Quickinsertionsattheend+Quickinsertionsinthemiddle+Quickiteratoraccess–Noindexedaccess507APPENDIXBQVector+Quickinsertionsattheend+Quickindexedaccess+Fastiteratoraccess+Usescontiguousmemory–Slowinsertionsatthestart–SlowinsertionsinthemiddleSpecializedContainersQStringListAQStringListisaQListwithbuilt-instringtreatmentmemberfunctions.
Thefollowinglistcoverssomeofthem:join:Joinsallthecontainedstringstogether,separatingthemwithagivenseparatorstring.
split:SplitsaQStringintoaQStringListbyusingagivenseparatorstring.
ThismethodisamemberoftheQStringclass.
replaceInStrings:Performsasearch-and-replaceoperationonallthecontainedstrings.
QStackAQStackisalistthatimplementsastack.
Youputnewitemsontopofthestackusingthepushmethod.
Youcanpeekatthetopitembyusingthetopmethodandyoucantakethetopitemwiththepopmethod.
QQueueAQQueueisalistthatimplementsaqueue.
Youcanputnewitemsattheendofthequeuewiththeenqueuemethod.
Youtakeitemsfromthebeginningofthequeueusingthedequeuemethod.
Youcanlookatthefirstiteminthequeuewithoutremovingitfromthelistusingtheheadmethod.
QSetAsetisacollectionofkeyswithoutanyorderorcount.
Youcaninsertnewkeysusingtheinsertmethodorthe,QLocale,qlonglong,QMap,QPoint,QPointF,QRect,QRectF,QRegExp,QSize,QSizeF,QString,QStringList,QTime,uint,qulonglong,andQUrl.
MostotherQttypesusedintheQtGuimodulecanalsobeusedwiththeQVariantclass.
ToconvertsuchatypetoaQVariant,simplyassignittotheQVariantobject.
ToconvertthemfromaQVariant,usethevaluemethod.
CautionIfyouareusingMSVC6.
0,youneedtouseqvariant_castinsteadofvalue.
SupportingCustomTypeswiththeVariantTosupportyourowntypesincombinationwiththeQVariantclass,youneedtoregisteritasaQMetaType.
YoucandothisbyusingtheQ_DECLARE_METATYPE(type)macro.
Youcanplacethismacroalongsideyourclassinyourheaderfile.
TobeabletouseyourclassinallsituationsinwhichtheQVariantclassisused,youneedtoregisteritthroughafunctioncallbycallingtheqRegisterMetaType(constchar*typeName).
Thetypenameshouldbethenameoftheclass;forexample:qRegisterMetaType("MySpecialType");APPENDIXBCONTAINERS,TYPES,ANDMACROS510Alltypesthatyouintendtouseinthiswaymustsupportapublicconstructorthatdoesnotneedanyarguments,aswellasapubliccopyconstructorandapublicdestructor.
MacrosandFunctionsQtcomeswithanumberofmacrosandfunctionsthatprovidecommonoperationsinaconvenientway.
Thefunctionsandmacrosaredividedintothreeparts:valueprocessingfunctions,functionsforrandomnumbers,andmacrosforiterations.
TreatingValuesWhendealingwithvalues,youoftenfindyourselflookingforthelargestvalue,thesmallestvalue,andsoon.
Allthesecomparisonsareavailableasfunctions:qMin(a,b):Returnsthesmallervalueofaandb.
qMax(a,b):Returnsthelargervalueofaandb.
qBound(min,v,max):Returnsthevaluevifitisbetweenminandmax;otherwise,returnsminifitislessthanminormaxifitislargerthanmax.
Ifminisgreaterthanmax,theresultisundefined.
TheqAbsfunctionisusedtofindtheabsolutevalueofthegivenargument.
YoucanusetheqRoundandqRound64functionstoroundqrealvaluestointegers.
TheqRoundfunctionreturnsanintvalue,meaningthattheresultcandifferbetweendifferentplatformsbecausethesizeofintcanvary.
Thispotentialplatform-relatedissueissolvedbyqRound64becauseitreturnsaqint64valuethatisofthesamesizeonallplatforms.
RandomValuesPseudorandomnumbersarehandledthroughtheqrandandqsrandfunctions.
Therandomnumbersareonlypseudorandombecausethesameseedgivesthesamesequenceofnum-bers.
Thismeansthatitisimportanttouseavaryingvalueastheseed.
Acommonvaluetouseisthecurrentsystemtime.
Theqrandfunctionreturnsthenextintegernumberinthenumbersequence,whileqsrandisusedtoseedthesequence.
Makesuretouseqsrandbeforeqrandifyoudowanttohaveapredictablesequenceofnumbers.
Thevaluereturnedfromqrandisofthetypeint.
Thismeansthatitssizecanvarybetweenplatforms.
Asimplewaytolimittherangeofagivenrandomnumberistousethemodulusoperatorcombinedwithanoffset.
Forexample,togeneratearandomnumberbetween15and30,youcanusethefollowinglineofcode:intvalue=15+qrand()%16;Thiscodecreatesarandomnumberbetween0and15usingthe%16operation.
Itthenadds15,movingtherangeto15through30.
APPENDIXBCONTAINERS,TYPES,ANDMACROS511IteratingWheniteratingoveralist,theforeach(variable,container)macroisveryhandy.
ThemacroworkswithallQtcontainers.
Forexample,toiterateoveraQStringList,usethefollow-inglineofcode:foreach(QStringvalue,valueList)doSomething(value);Whenyouwanttoiterateforever,itiscommontouseanemptyforloop(for(oraneverlastingwhileloop(while(true).
.
.
).
Tomakeyourcodeeasiertoread,usetheforevermacroinstead.
Thefollowinglineshowshowitcanlookinpractice:foreverdoSomething();Ifyoudon'twantQttoaddtheforeachandforeverkeywordstoyourglobalnamespace,addtheno_keywordsvaluetoyourCONFIGvariableinyourprojectfile.
YoucanstillusetheforeachmacrothroughtheQ_FOREACHname.
TheforeachmacroisavailableasQ_FOREVER.
APPENDIXBCONTAINERS,TYPES,ANDMACROS512Symbols*.
*Allfiles()filter,78=assignmentoperator,447[]operator,24,27,30\backslash,89^XORlogicaloperator,28|pipecharacter,368#hashcharacter,446,462>redirectoperators,239,241,25QListIteratorclass,22QListViewclass,124QListWidgetclass,69,124,320,328QListWidgetItemclass,69QLocaleclass,284,296–300qmfiles,280QMainWindowclass,268qmakecommand,12,19,445,449qmake-projectcommand,323QMaketool,11,18,47,445–457complexprojectsand,454Qtmodulesand,449running,449QMapclass,27–29,321,509QMessageBoxclass,62,80,102QMetaObjectclass,15,148QMetaTypeclass,510QModelIndexclass,137QMouseEventclass,165,167,169QMultiHashclass,29,31,509QMultiMapclass,29,509QMutableListIterator,23QMutexclass,337,341,339QMutexLockerclass,339qNametag,250QnnClassNamenamingconvention,7QObjectclass,7,21,145applicationtranslationsand,288eventfiltersand,170pluginsand,303,318threadsand,359UDPserversand,440headerfile,7qobject_cast()method,303,322,325QPaintDeviceclass,183QPainterclass,131,183–233customwidgetsand,175textand,193QPainterPathclass,196QPaintEventclass,167QPictureclass,183QPixmapclass,183,193,431QPluginLoaderclass,303,321,323,328–332QPointclass,186QPointFclass,186INDEX522QPolygonclass,187QPolygonFclass,216QPrintDialogclass,229QPrinterclass,228–232QProcessclass,363–368QProgressBarclass,74QPushButtonclass,34,62,205,208,269FTPconnectionsand,407TCPclientsand,430QPushButtonsclass,keypadsand,157QQueueclass,26,508QRadialGradientclass,198QRadioButtonclass,67,205qrcfileextension,112,448QReadLockerclass,341QReadWriteLockclass,341QRectclass,186,189,207QRectFclass,186QRegExpclass,88QRegExpValidatorclass,91qRegisterMetaType()method,356QScrollBarclass,74QSemaphoreclass,345QSetclass,29,508QShowEventclass,167QSignalMapperclass,106,159QSignalSpyclass,490QSizeclass,206QSizePolicyclass,59QSliderclass,73,134QSortFilterProxyModel,153QSpacerItem,59QSpinBoxclass,72,483QSplitterclass,124QSqlDatabaseclass,378,382,392QSqlErrorclass,379QSqlQueryclass,380,382QSqlQueryModel,399QSqlRecordclass,380QSqlRelationclass,400QSqlRelationalDelegateclass,401QSqlRelationalTableModel,400QSqlTableModel,399QStackclass,26,508QStandardItemclass,126QStandardItemModel,125,139,153QStatusBarclass,267QStreamWriterclass,428QStringclass,10,20,110applicationtranslationsand,295filedialogsand,77threadsand,353–359QStringListclass,25,83,128,364,508filedialogsand,77imagecollectionsampleapplicationand,389,393imagefileformatsand,308updatingpluginsand,327QStringListModel,128QStyleclass,207QStyleOptionclass,130QStyleOptionButtonclass,207Qtcommerciallicensefor,3creatingapplicationsin,11,18–21,103,111databasesand,371,378–382developmentenvironmentinstallationfor,3namingconventionsand,6unittestingand,472QT+=xml,244Qt4.
2.
2CommandPrompt(Windows),11QtbyTrolltechfolder,5Qtcommandprompt,5QT4_ADD_RESOURCEScommand,460QT4_WRAP_CPPcommand,458,460QT4_WRAP_UIcommand,458,460QTableViewclass,124,144QTableWidgetclass,124qtbookexample.
adp(AssistantDocumentationProfile),275QTcpServerclass,426QTcpSocketclass359,427–432QTESTmacro,480,487,498QTEST_MAINmacro,473,476QTextDocumentclass,116,195QTextEditclass,65,95,166,271,364DocumentWindowclassand,104eventsand,164QTextStreamclass,239,252,309,311QThreadclass,333,359QTimeclass,298QTimeEditclass,73QTimerclass,162,211,359,440QtModuleclass,479–482QtNetworkmodule,403QtopiaCore,304QTranslationclass,294QTranslatorclass,284,292qTranslatorpointer,294QTreeViewclass,124QTreeWidgetclass,124QtSqlmodule,371,378QtTestmodule,472–483,491QtXmlmodule,244QT_TRANSLATE_NOOPmacro,288QT_TR_NOOPmacro,288qt_untranslated.
tsfile,285QUdpSocketclass,359,436,440queries,databasesand,380querymodel,399questionmarkbutton,indialogtitlebar,263question()method,80,102queuedconnections,customtypesand,356queues,26,508QUrlclass,417QValidatorclass,87QVariantclass,142,151,381,510QVBoxLayoutclass,60,172QVectorclass,24,508QVERIFYmacro,475,480,498INDEX523Finditfasterathttp://superindex.
apress.
com/QWARNmacro,489qWarning()method,9QWhatsThisClickedEvent,266QWheelEventclass,175QWidgetclass,158,210,269QWidgetStackclass,269QWorkspaceclass,104,111QWriteLockerclass,341Qwt,502QwtDataclass,502QXmlAttributesclass,250QXmlContentHandlerclass,248QXmlDefaultHandlerclass,249QXmlInputSourceclass,248QXmlSimpleReaderclass,248Q_DECLARE_INTERFACEmacro,303,326Q_DECLARE_METATYPEmacro,357Q_EXPORT_PLUGIN2macro,181,308,319,325Q_IMPORT_PLUGINmacro,325Q_INTERFACESmacro,303Q_OBJECTmacro,14,19,48Rradialgradients,198radiobuttons,67randomnumbers,511rawCommand()method,417rawCommandReply()method,417read()method,309,311read-onlyitems,creating,127read-onlytablemodels,141read-writelocks,341–344,350readAll()method,240,252readAllStandardError()method,364readAllStandardOutput()method,364readDatagram()method,438readLine()method,240readOnlyproperty,271readyRead()method,423TCPclientsand,432UDPclientsand,438readyReadStandardError()method,364readyReadStandardOutput()method,365rect()method,207rectanglesdrawing,189handlesformanipulating,220text,drawingwithin,193redirectoperators(>),239,241reflectedspread,198regularexpressions,88–92reject()method,271relationaldatabases,371.
Seealsodatabasesrelationaltablemodel,400releasescope,450release()method,345releaseKeyboard()method,168releaseMouse()method,169releasingtranslations,280,283remove()method,HTTPclientsand,422render()method,231repaint()method,205repeatspread,198requestFinished()method,423requestStarted()method,423reset()method,progressbarand,74resizeEvent()method,165resolve()method,331ResourceEditor(Designer),37resourcefiles,112CMakeand,460qmfiles,addingto,284QMakeand,448responseHeaderReceived()method,423restore()method,131retranslateUifunction,49right-clickmenus,168RightHandlerole,221roles,63,141root()method,235roundshapes,drawing,191roundedlinesegment,188rowCount()method,141,151run()methodsendingimagesand,427threadingapplicationand,334Runningstate,processesand,364Ssave()method,304,316saveFile()method,250,253SAX(SimpleAPIforXML),readingXMLfileswith,244,248scenes,graphicsviewframeworkand,215scopes,450scrollbars,74,137SDI(singledocumentinterface),96–103,111sdi.
proprojectfile,281SdiWindowclass,103,117,250SELECTcommand,373joiningtablesand,375mathematicalfunctionsand,377selectedItems().
count()method,70selectedTags()method,385,389selectionmodel,126selection()method,137selectionBehaviorproperty,128selectionChanged()method,139,405,411selectionModeproperty,69,128,411selections,limiting,127selectionUpdated()method,FTPclientsand,415semaphores,344–352semicolons,double(;;),76separatorAction()method,106sequences,507serializeddata,241serverapplications,425serverPortproperty,426INDEX524servers,425TCP,425–429UDP,440SETcommand,458,461setAttribute()method,214setBrush()method,184,198setColorAt()method,199setContentHandler()method,248setData()method,135,150,152setDevice()method,309setDirection()method,60setEditable()method,127setEditorData()method,132,134setEnabled()method,271setFileName()method,238,331setFilter()method,237setFlag()method,223setHeaderData()method,401setHorizontalHeaderItem()method,127setHost()method,421setHtml()method,271setItem()method,126setMapping()method,159setModel()method,126setModelData()method,132,135setNameFilters()method,238setPen()method,184setPixel()method,438setPixmap()method,431setPlainText()method,252setRelation()method,400sets,29,508setScene()method,216setSelectionModel()method,126setShortcut()method,99setSocketDescriptor()method,428setSourceModel()method,153setSpread()method,198setStatusTip()method,99setStringList()property,128settermethods,6,14,59setText()method,15,20,65,159setTexture()method,200setTextWidth()method,195setTooltip()method,258setupUi()method,49,321setUser()method,421setValidator()method,87setValue()method,23,74,134,172,174setVersion()method,241setVerticalHeaderItem()method,127setWhatsThis()method,263setZValue()method,220shell,processesand,368showEvent()method,165,167showLink()method,265showMessage()method,267showPage()method,277showText()method,362SIGNALmacro,16signalmappers,106Signal/SlotEditor,36,45signals,13–21,44comboboxesand,71connecting,16HTTPclientsand,423processesand,363–368testing,490threadsand,352–359SimpleAPIforXML(SAX),readingXMLfileswith,244,248single-columnlists,128singleinheritance,50singleStepproperty,72,73sizehints,57sizepolicies,57custom,59layoutsand,61sizeHint()method,129,173,205,211,269sizePolicyproperty,57,59slash(/),pathsand,235sleep()method,threadingapplicationand,334sliders,39,73,74SLOTmacro,16slots,13–21,44centralwidgetand,96connecting,16imagecollectionsampleapplicationand,385–389mainwindowand,96processesand,363–368threadsand,352–359.
sofiles,330socketdescriptors,427sockets,424–442sort()method,153sortingmodels,153sortingEnabledproperty,153SortOnSecondModel,154sourcemodels,153,155sourceModel()method,155specializedcontainers,507spinboxes,72,483split()method,25splitters,124spreadpolicies,198SQL(StructuredQueryLanguage),371–382,398–401SQLmodule,threadsand,359SQLite,371connectionfor,379imagecollectionsampleapplicationand,382–397squarebrackets([]),89squareshapes,drawing,189stacks,26,508standarderrorchannels,processesand,363standardinputchannels,processesand,363standarditemmodels,125,127standardoutputchannels,processesand,363INDEX525Finditfasterathttp://superindex.
apress.
com/standardtemplatelibrary(STL),10started()method,364startElement()method,249Startingstate,processesand,364stateChanged()method,66,364,423,432staticplacement,55staticInstances()method,325statusbars,267–269,301statusBar()method,101,267STL(standardtemplatelibrary),10STL-styleiterators,22streams,239–243stretchfactors,60stringlists,128,508.
SeealsoQStringListclassstrings.
SeealsoQStringclasspassingbetweenthreads,353–356regularexpressionsand,88–92tr()methodand,98translationsand,281,285–295validating,87,91StructuredQueryLanguage(SQL),371–382,398–401styleoptions,130styleproperty,188,207styles,fordrawing,206supportmethods,389supportedImageFormats()method,316switchoperation,273switchstatement,81synchronizingthreads,336–344system()method,284Ttaborder,45tablemodel,399tables,123joining,375relationaldatabasesand,371tablemodelfor,399tagName()method,246tags,testing,492–496tagsChangedslot,387takeItem()method,70TARGET_LINK_LIBRARIEScommand,458,467TCPclients,429–435TCPprotocol,424–435reliabilityand,424sendingimagesvia,425–435TCPservers,425–429tcpError()method,435technicalapplications,Qwtfor,502temp()method,235templateclasses,21testvectors,479testAttribute()method,215testClicks,483–491testing,471–498delegates,131tags,492–496testKeys,483–491testSetting,483–491textapplicationtranslationsand,295buttons,drawingtextwithin,207drawing,193–196labeltextand,39,57,64,83,137formatting,195rectangles,drawingtextwithin,193textdevices,339textdocuments,195texteditor,96textimages,306textproperty,43,176textstreams,239,309text()method,65,160textChanged()method,14,19,65,159TextImageHandlerclass,306,309,314TextImageIOHandlerclass,308TextImagePluginclass,306,309textures,paintingand,198,200textVisibleproperty,progressbarand,74thispointer,50threadaffinity,359threads,333–362deadlocksand,345main,333pitfallsof,359processesand,333,363–368sharingresourcesamong,344–352signals/slotsand,352–359synchronizing,336–344terminating,336threadaffinityand,359tifiles,306tileAction()method,106time.
Seedateandtimetimeout()method,162,211,440timers,162,211toBool()method,381toDouble()method,88,92,381toDoublt()method,297toElement()method,246toFloat()method,296toggled()method,62,66,98buttonsand,67checkboxesand,271groupboxesand,68on-the-flyapplicationtranslationsand,292toggleViewAction()method,118toInt()method,88,131,296,381tools.
SeeutilitiesToolTipevents,260toolTip()method,180tooltips,180,257–262applicationtranslationsand,301images,insertinginto,260top()method,26TopHandlerole,221toStdString()method,11toString()method,245,296,298,381INDEX526toText()method,246tr()method,98,281translate()method,287translateUi()method,293translatingapplications,279–295on-the-flytranslationsand,292stringsand,281,285–295transmissioncontrolprotocol.
SeeentriesatTCPtrees,123,144triggered()method,98,106tryAcquire()method,345tryLock()method,337tsfiles,280typedef,22types,509UUDPclients,437UDPprotocol,424,436–442,424UDPservers,440UI(userinterface),33actionsand,34FTPclientsand,406HTTPclientsand,419imagecollectionsampleapplicationand,384–392QCoreApplicationclassand,425serverapplicationsand,425TCPclientsand,430threadsand,360widgetsand,55–93uicapplication,363ultag(HTML),tooltipsand,260UML(UnifiedModelingLanguage),34Unicodecharacters,applicationtranslationsand,295UnifiedModelingLanguage(UML),34unittesting,471–498datadriven,479–482,487handlingdeviationsand,497structureof,472UnixplatformsCMakeand,459,464drivesand,235iconsand,115installingQton,3QMakeand,452QPixmapclassand,184unixscope,450unlock()method,337,339UPDATEcommand,375update()method,174,205updateCurrentImage()method,385,387,390updateEditorGeometry()method,132updateImages()method,385,387,390updateTags()method,385,388,390updateText()method,136,139updateTime()method,162updateWindowList()method,108URLs,parsing/validating,417usecases,inUML,34userdatagramprotocol.
SeeentriesatUDPuserinterface.
SeeUIusersaskingquestionsof,80interactionwith,testing,483–490selectionsby,limiting,127validatinginputfrom,86–92usleep()method,threadingapplicationand,334UTF8format,applicationtranslationsand,295utilitiesCMake.
SeeCMakeDependencyWalker,329Designer.
SeeDesignerLinguist,281,285lrelease,283lupdate,281,283,287mingw.
exe,5moc(meta-objectcompiler),15objdump,329QMaketool.
SeeQMakethird-party,501–505Vvalidatinguserinput,86–92validators,87–88,91value()method,27,174,381valueChanged()method,172slidersand,74spinboxesand,72testing,490values,gettingfromusers,84values()method,29valuesprocessingfunctions,511variables,QMakeand,446vectors,24,508versioncontrolsystems,outsidesourcebuildsand,457versioning,241verticallayouts,59verticalsliders,74verticalspacers,55Viewmenu,dockablewidgetsand,118viewport,137viewportproperty,232viewportEvent()method,261views,124–140creating,124custom,129–140graphicsviewframeworkand,215Wwait()method,335waitForDisconnect()method,428warningmessage,80warning()method,80,102What'sthishelptips,263–267,301whatsThis()method,180WhatsThisClickedevents,264INDEX527Finditfasterathttp://superindex.
apress.
com/wheelevents,175wheelEvent()method,165,173,175whitespace,51widgetbox(Designer),36widgetpluginclasses,178widgets,19,55–93buddy,64centralwidgetand,96composite,157–176creating/customizing,157–182custom,171–176,210–215dockable,115drawing,183–204imagecollectionsampleapplicationand,385–389integratingwithDesigner,176–182painting,204–215propertiesfor,43sizepoliciesfor,57statusbar,addingto,267unittestingfor,483–490widthproperty,linesand,188win32scope,450Windowmenu,108windowActivated()method,105windowModifiedproperty,98,105windows,arrangingdocumentsin,95–112WindowsplatformCMakeand,459,462drivesand,235iconsand,114installingQton,5QMakeand,450windowstitleproperty,forwidgets,43WindowsXPstyle,64wizards,269–275word-wrapping,263workingmodes,displaying,269workspace,104,111write()method,309,339writeDatagram()method,441wwWidgetslibrary,503XX11platform,QPixmapclassand,184XML,243–250DOMand,244–248modifyingfilesand,247QT+=xmlfor,244SAX,readingfileswith,248translatingapplicationsand,280XMLfilescreating,244referencinginprojects,47XORlogicaloperator(^),28ZZvalue,220INDEX528
Hostinger 商家我们可能一些新用户不是太熟悉,因为我们很多新人用户都可能较多的直接从云服务器、独立服务器起步的。而Hostinger商家已经有将近十年的历史的商家,曾经主做低价虚拟主机,也是比较有知名度的,那时候也有接触过,不过一直没有过多的使用。这不这么多年过去,Hostinger商家一直比较稳妥的在运营,最近看到这个商家在改版UI后且产品上也在活动策划比较多。目前Hostinger在进...
3C云国内IDC/ISP资质齐全商家,与香港公司联合运营, 已超6年运营 。本次为大家带来的是双12特惠活动,香港美国日本韩国|高速精品|高防|站群|大带宽等产品齐全,欢迎咨询问价。3C云科技有限公司官方网站:http://www.3cccy.com/客服QQ:937695003网页客服:点击咨询客户QQ交流群:1042709810价目表总览升级内存 60元 8G内存升级硬盘 1T机械 90元 2...
搬瓦工和Vultr哪个好?搬瓦工和Vultr都是非常火爆的国外VPS,可以说是国内网友买的最多的两家,那么搬瓦工和Vultr哪个好?如果要选择VPS,首先我们要考虑成本、服务器质量以及产品的售后服务。老玩家都知道目前在国内最受欢迎的国外VPS服务商vultr和搬瓦工口碑都很不错。搬瓦工和Vultr哪个稳定?搬瓦工和Vultr哪个速度快?为了回答这些问题,本文从线路、速度、功能、售后等多方面对比这两...
plugin-container.exe为你推荐
状态微信5contentcss平板ipad存在问题的应用软件名单(2020年第四批)支持ipad特斯拉苹果5iphone连不上wifi我的苹果手机连不上无线,其它手机能,怎么回事?只是家里的连不上iexplore.exe应用程序错误iexplore.exe应用程序错误ipad上网ipad上网速度很慢怎么回事?csshack什么是Css Hack?ie6,7,8的hack分别是什么
虚拟主机服务 免费linux主机 河南vps 二级域名申请 华为云服务 私服服务器 外国空间 名片模板psd parseerror php免费空间 镇江联通宽带 一元域名 南昌服务器托管 国外在线代理 qq数据库下载 炎黄盛世 hkg 刀片式服务器 徐正曦 美国堪萨斯 更多