Advanced Qt Programming

Total Page:16

File Type:pdf, Size:1020Kb

Advanced Qt Programming ptg From the Library of Wow! eBook Advanced Qt Programming ptg From the Library of Wow! eBook This page intentionally left blank ptg From the Library of Wow! eBook Advanced Qt Programming Creating Great Software with C+ + and Qt 4 Mark Summerfield ptg Upper Saddle River, NJ ·Boston ·Indianapolis ·San Francisco p New York ·Toronto ·Montreal ·London ·Munich ·Paris ·Madrid p Capetown ·Sydney ·Tokyo ·Singapore ·Mexico City From the Library of Wow! eBook Many of the designations used by manufacturers and sellers to distinguish their products are claimed as trademarks. Where those designations appear in this book, and the publisher was aware of a trademark claim, the designations have been printed with initial capital letters or in all capitals. The author and publisher have taken care in the preparation of this book, but make no expressed or implied warranty of any kind and assume no responsibility for errors or omissions. No liability is assumed for incidental or consequential damages in connection with or arising out of the use of the information or programs contained herein. The publisher offers excellent discounts on this book when ordered in quantity for bulk purchases or special sales, which may include electronic versions and/or custom covers and content particular to your business, training goals, marketing focus, and branding interests. For more information, please contact: U.S. Corporate and Government Sales (800) 382-3419 [email protected] For sales outside the United States, please contact: International Sales [email protected] Visit us on the Web: informit.com/aw Library of Congress Cataloging-in-Publication Data Summerfield, Mark. Advanced Qt programming : creating great software with C++ and Qt 4 / Mark Summerfield. p.mcm. Includes bibliographical references and index. ptg ISBN 978-0-321-63590-7 (hardcover : alk. paper) 1. Qt (Electronic resource) 2. Graphical user interfaces (Computer systems) 3. C++ (Computer program language) I. Title. QA76.9.U83S88 2010 005.1’13—dc22 2010019289 Copyright © 2011 Qtrac Ltd. All rights reserved. Printed in the United States of America. This publication is protected by copyright, and permission must be obtained from the publisher prior to any prohibited reproduction, storage in a retrieval system, or transmission in any form or by any means, electronic, mechanical, photocopying, recording, or likewise. For information regarding permissions, write to: Pearson Education, Inc. Rights and Contracts Department 501 Boylston Street, Suite 900 Boston, MA 02116 Fax: (617) 671-3447 ISBN-13: 978-0-321-63590-7 ISBN-10: 0-321-63590-6 Text printed in the United States on recycled paper at Courier in Westford, Massachusetts. First printing, July 2010 From the Library of Wow! eBook This book is dedicated to Anna Rebecca Paterson ptg From the Library of Wow! eBook This page intentionally left blank ptg From the Library of Wow! eBook Contents at a Glance List of Tables . ........................................................................................... xiii Foreword . .................................................................................................. xv Introduction . ............................................................................................. 1 Chapter 1. Hybrid Desktop/Internet Applications ............................... 5 Chapter 2. Audio and Video ................................................................. 53 Chapter 3. Model/View Table Models ................................................. 87 Chapter 4. Model/View Tree Models .................................................... 129 Chapter 5. Model/View Delegates . ...................................................... 185 Chapter 6. Model/View Views .............................................................. 207 Chapter 7. Threading with QtConcurrent . ............................................ 245 ptg Chapter 8. Threading with QThread . .................................................... 287 Chapter 9. Creating Rich Text Editors .................................................... 317 Chapter 10. Creating Rich Text Documents . ....................................... 359 Chapter 11. Creating Graphics/View Windows .................................... 389 Chapter 12. Creating Graphics/View Scenes . .................................... 409 Chapter 13. The Animation and State Machine Frameworks ............. 469 Epilogue . .................................................................................................. 491 Selected Bibliography . ........................................................................... 495 Index . ........................................................................................................ 499 www.qtrac.eu/aqpbook.html vii From the Library of Wow! eBook This page intentionally left blank ptg From the Library of Wow! eBook Contents List of Tables . ........................................................................................... xiii Foreword . .................................................................................................. xv Introduction . ............................................................................................. 1 Acknowledgements . 3 Chapter 1. Hybrid Desktop/Internet Applications . 5 Internet-Aware Widgets . 6 Using WebKit . ..................................................................................... 21 A Generic Web Browser Window Component . .................... 22 ptg Creating Web Site-Specific Applications . ............................... 30 Embedding Qt Widgets in Web Pages .................................... 44 Chapter 2. Audio and Video ................................................................. 53 Using QSound and QMovie .............................................................. 54 The Phonon Multimedia Framework . .............................................. 60 Playing Music . ........................................................................... 64 Playing Videos ........................................................................... 80 Chapter 3. Model/View Table Models . ................................................. 87 Qt’s Model/View Architecture . ...................................................... 88 Using QStandardItemModels for Tables . ....................................... 90 Changing a Table Model through the User Interface . .......... 91 A QStandardItemModel Subclass for Tables .......................... 102 A QSortFilterProxyModel to Filter Out Duplicate Rows . .......... 107 A QSortFilterProxyModel to Filter In Wanted Rows .................. 109 Creating Custom Table Models . 113 Changing a Table Model through the User Interface . 113 A Custom QAbstractTableModel Subclass for Tables . 116 The QAbstractItemModel API Methods for Tables . 117 Methods to Support Saving and Loading Table Items . 126 From the Library of Wow! eBook ix Chapter 4. Model/View Tree Models .................................................... 129 Using QStandardItemModels for Trees ............................................ 130 Changing a Tree Model through the User Interface . ............. 131 A QStandardItem Subclass for Tree Items ............................... 141 A QStandardItemModel Subclass for Trees . .......................... 143 Creating Custom Tree Models ......................................................... 151 Changing a Tree Model through the User Interface . 152 A Custom Item Class for Tree Items . 155 A Custom QAbstractItemModel Subclass for Trees . 158 The QAbstractItemModel API for Trees . 160 The QAbstractItemModel API for Drag and Drop . 168 Methods for Saving and Loading Tree Items . 180 Chapter 5. Model/View Delegates . 185 Datatype-Specific Editors . 186 Datatype-Specific Delegates . ptg 188 A Read–Only Column or Row Delegate . 188 An Editable Column or Row Delegate . 193 Model-Specific Delegates . .............................................................. 201 Chapter 6. Model/View Views . .............................................................. 207 QAbstractItemView Subclasses . .................................................... 208 Model-Specific Visualizing Views . ................................................... 224 The Visualizer Widget . .............................................................. 225 The Visualizer’s Aggregated Header Widget . ....................... 232 The Visualizer’s Aggregated View Widget . ............................ 235 Chapter 7. Threading with QtConcurrent . ............................................ 245 Executing Functions in Threads . 248 Using QtConcurrent::run() . 252 Using QRunnable . 257 Filtering and Mapping in Threads .................................................... 261 Using QtConcurrent to Filter . .................................................... 270 Using QtConcurrent to Filter and Reduce ............................... 277 Using QtConcurrent to Map .................................................... 281 Chapter 8. Threading with QThread ...................................................... From the Library of 287Wow! eBook Processing Independent Items . ...................................................... 287 Processing Shared Items ................................................................... 302 x Chapter 9. Creating Rich Text Editors . ................................................... 317 Introducing QTextDocument . ......................................................... 318 Creating Custom Text Editors . ........................................................
Recommended publications
  • Red Hat Enterprise Linux 6 Developer Guide
    Red Hat Enterprise Linux 6 Developer Guide An introduction to application development tools in Red Hat Enterprise Linux 6 Dave Brolley William Cohen Roland Grunberg Aldy Hernandez Karsten Hopp Jakub Jelinek Developer Guide Jeff Johnston Benjamin Kosnik Aleksander Kurtakov Chris Moller Phil Muldoon Andrew Overholt Charley Wang Kent Sebastian Red Hat Enterprise Linux 6 Developer Guide An introduction to application development tools in Red Hat Enterprise Linux 6 Edition 0 Author Dave Brolley [email protected] Author William Cohen [email protected] Author Roland Grunberg [email protected] Author Aldy Hernandez [email protected] Author Karsten Hopp [email protected] Author Jakub Jelinek [email protected] Author Jeff Johnston [email protected] Author Benjamin Kosnik [email protected] Author Aleksander Kurtakov [email protected] Author Chris Moller [email protected] Author Phil Muldoon [email protected] Author Andrew Overholt [email protected] Author Charley Wang [email protected] Author Kent Sebastian [email protected] Editor Don Domingo [email protected] Editor Jacquelynn East [email protected] Copyright © 2010 Red Hat, Inc. and others. The text of and illustrations in this document are licensed by Red Hat under a Creative Commons Attribution–Share Alike 3.0 Unported license ("CC-BY-SA"). An explanation of CC-BY-SA is available at http://creativecommons.org/licenses/by-sa/3.0/. In accordance with CC-BY-SA, if you distribute this document or an adaptation of it, you must provide the URL for the original version. Red Hat, as the licensor of this document, waives the right to enforce, and agrees not to assert, Section 4d of CC-BY-SA to the fullest extent permitted by applicable law.
    [Show full text]
  • Lively Mashups for Mobile Devices
    Lively Mashups for Mobile Devices Feetu Nyrhinen, Arto Salminen, Tommi Mikkonen Tampere University of Technology Antero Taivalsaari Sun Microsystems Laboratories Outline • Background • Mashups • Mashup Development and Tools • Lively Mashups • Qt as a Mashup Platform • Mashup demos • Experiences • Conclusions Background • Web as the platform • End-user software is moving to the Web. • Typical examples: project management, calendars, document management, instant messaging, social networking, … • Web browser acts as a replacement for the conventional OS. • Mobile devices are becoming web-enabled, but there still are constraints such as smaller screen size, battery consumption, lower CPU speed and network bandwidth. Mashups • Mashup: A web site that combines content from more than one source (multiple web sites) into an integrated experience. • Mashups leverage the power of the Web to support worldwide sharing of content that would not have been easily accessible or reusable before the Web. • In principle, the content to be combined can be anything (text, source code, maps, video, blogs, product reviews, price data, ...) as long as it can be meaningfully combined with other content. • See, e.g., http://woozor.us/ (Weather conditions on Google Map) Mashup Development and Tools • There is a plethora of various tools for the mashup development. • However, general tools are still fairly limited in functionality and many of those are far from finished applications. • Some common trends: • Using the web not only for executing applications but also for developing them. • Visual programming techniques. • The web server is used to host and share mashups. • Direct connections to existing web services. • Mashup development for mobile devices is still a field with big challenges.
    [Show full text]
  • Kde-Guide-De-Developpement.Web.Pdf
    KDE Published : 2017-06-26 License : GPLv2+ 1 KDE DU POINT DE VUE D'UN DÉVELOPPEUR 1. AVEZ-VOUS BESOIN DE CE LIVRE ? 2. LA PHILOSOPHIE DE KDE 3. COMMENT OBTENIR DE L'AIDE 2 1. AVEZ-VOUS BESOIN DE CE LIVRE ? Vous devriez lire ce livre si vous voulez développer pour KDE. Nous utilisons le terme développement très largement pour couvrir tout ce qui peut conduire à un changement dans le code source, ce qui inclut : Soumettre une correction de bogue Écrire une nouvelle application optimisée par la technologie KDE Contribuer à un projet existant Ajouter de la fonctionnalité aux bibliothèques de développement de KDE Dans ce livre, nous vous livrerons les bases dont vous avez besoin pour être un développeur productif. Nous décrirons les outils que vous devrez installer, montrer comment lire la documentation (et écrire la vôtre propre, une fois que vous aurez créé la nouvelle fonctionnalité !) et comment obtenir de l'aide par d'autres moyens. Nous vous présenterons la communauté KDE, qui est essentielle pour comprendre KDE parce que nous sommes un projet « open source », libre (gratuit). Les utilisateurs finaux du logiciel n'ont PAS besoin de ce livre ! Cependant, ils pourraient le trouver intéressant pour les aider à comprendre comment les logiciels complexes et riches en fonctionnalités qu'ils utilisent ont vu le jour. 3 2. LA PHILOSOPHIE DE KDE Le succès de KDE repose sur une vue globale, que nous avons trouvée à la fois pratique et motivante. Les éléments de cette philosophie de développement comprennent : L'utilisation des outils disponibles plutôt que de ré-inventer ceux existants : beaucoup des bases dont vous avez besoin pour travailler font déjà partie de KDE, comme les bibliothèques principales ou les « Kparts », et sont tout à fait au point.
    [Show full text]
  • Eagle: Tcl Implementation in C
    Eagle: Tcl Implementation in C# Joe Mistachkin <[email protected]> 1. Abstract Eagle [1], Extensible Adaptable Generalized Logic Engine, is an implementation of the Tcl [2] scripting language for the Microsoft Common Language Runtime (CLR) [3]. It is designed to be a universal scripting solution for any CLR based language, and is written completely in C# [4]. Su- perficially, it is similar to Jacl [5], but it was written from scratch based on the design and imple- mentation of Tcl 8.4 [6]. It provides most of the functionality of the Tcl 8.4 interpreter while bor- rowing selected features from Tcl 8.5 [7] and the upcoming Tcl 8.6 [8] in addition to adding en- tirely new features. This paper explains how Eagle adds value to both Tcl/Tk and CLR-based applications and how it differs from other “dynamic languages” hosted by the CLR and its cousin, the Microsoft Dy- namic Language Runtime (DLR) [9]. It then describes how to use, integrate with, and extend Ea- gle effectively. It also covers some important implementation details and the overall design phi- losophy behind them. 2. Introduction This paper presents Eagle, which is an open-source [10] implementation of Tcl for the Microsoft CLR written entirely in C#. The goal of this project was to create a dynamic scripting language that could be used to automate any host application running on the CLR. 3. Rationale and Motivation Tcl makes it relatively easy to script applications written in C [11] and/or C++ [12] and so can also script applications written in many other languages (e.g.
    [Show full text]
  • Latex Beamer Presentation
    Extend your KDE application Using QML! Artur Duque de Souza Aug/2011 Agenda • (Big) Introduction • A problem • KDE Solution • Issues • Future Qt Script QtScript C++ API to make your applications scriptable QScriptEngine • Environment to evaluate a script • Context • Global Object • Use QMetaObject system to automatically export QObjects QObjects Can be exported out of the box: • Properties • Signals • Slots • Q_INVOKABLE QScriptValue Container for QtScript data types: • Support for ECMA-262 types • Support for QObject, QVariant and QMetaObject • Prototype property that is common to all instances of an object JS Bindings JS Bindings for Qt Bindings are proxy objects/functions to interface with the ’real’ libraries JS Bindings for Qt Steps to create your bindings: • Create wrap code (check context arguments) • Register your wrappers with the engine • Be happy :) JS Bindings for Qt Steps to create your bindings: • Create wrap code (check context arguments) • Register your wrappers with the engine • Be happy :) JS Bindings for Qt Steps to create your bindings: • Create wrap code (check context arguments) • Register your wrappers with the engine • Be happy :) QML QML Declarative language to ease the development of UIs QDeclarativeEngine • Handles QML code • Does not inherit QScriptEngine • It has a QScriptEngine inside QDeclarativeEngine • Handles QML code • Does not inherit QScriptEngine • It has a QScriptEngine inside QDeclarativeEngine Public API • QML specific methods • It has its own ’context’: QDeclarativeContext • QObject works out of the box • It’s possible to register C++ declarative items QDeclarativeExpression Evaluate a JS expression in a QML context KDE First of all... ... why use QML? Declarative languages are way better (and faster) to build rich UIs! • Microblog plasmoid (C++): 1250 LOC • Declarative Microblog: 500 LOC First of all..
    [Show full text]
  • Preview Tcl-Tk Tutorial (PDF Version)
    Tcl/Tk About the Tutorial Tcl is a general purpose multi-paradigm system programming language. It is a scripting language that aims at providing the ability for applications to communicate with each other. On the other hand, Tk is a cross platform widget toolkit used for building GUI in many languages. This tutorial covers various topics ranging from the basics of the Tcl/ Tk to its scope in various applications. Audience This tutorial is designed for all those individuals who are looking for a starting point of learning Tcl/ Tk. Therefore, we cover all those topics that are required for a beginner and an advanced user. Prerequisites Before proceeding with this tutorial, it is advisable for you to understand the basic concepts of computer programming. This tutorial is self-contained and you will be able to learn various concepts of Tcl/Tk even if you are a beginner. You just need to have a basic understanding of working with a simple text editor and command line. Disclaimer & Copyright Copyright 2015 by Tutorials Point (I) Pvt. Ltd. All the content and graphics published in this e-book are the property of Tutorials Point (I) Pvt. Ltd. The user of this e-book is prohibited to reuse, retain, copy, distribute, or republish any contents or a part of contents of this e-book in any manner without written consent of the publisher. We strive to update the contents of our website and tutorials as timely and as precisely as possible, however, the contents may contain inaccuracies or errors. Tutorials Point (I) Pvt.
    [Show full text]
  • KDE Galaxy 4.13
    KDE Galaxy 4.13 - Devaja Shah About Me ●3rd Year Alienatic Student at DA- !"# Gandhinagar ●Dot-editor %or KDE &romo "ea' ●Member of KDE e.(. ●&a))ion for Technology# Literature ●+un the Google Developer Group in !olle$e ●-rganizin$ Tea' of KDE Meetup# con%./de.in 14 -/ay, sooooo....... ●Ho1 many of you are %an) of Science Fiction3 ●Astronomy3 ● 0o1 is it Related to KDE3 ●That i) precisely 1hat the talk is about. ●Analogy to $et you to kno1 everythin$ that you should about ● “Galaxy KDE 4.13” 4ait, isn't it 4.14? ●KDE5) late)t ver)ion S! 4.14 6 7ove'ber 8914 ●KDE Soft1are !o',ilation ::.xx ●Significance o% +elea)e) ●- -r$ani.ed# )y)te'atic co',ilation o% %eature) < develo,'ent) ●- 2ive )erie) of relea)e) till date. ●7o Synchronized +elea)e) Any lon$er: ● - KDE 2ra'e1ork) > ?'onthly@ ● - KDE &la)'a > ?3 'onth)@ ● - KDE Ap,lication) ?date ba)ed@ ●Au)t *i/e Ap, (er)ion) But, 1hat am I to do o% the Galaxy 7umber? ●4ork in a "eam ●4ork acros) a Deadline ●-%;ce Space Si'ulation ●Added 'petus %or Deliverin$ your 2eature) ●You 1ork a) a ,art of the C!oreD Developer "ea' ● nstils Discipline ●Better +e),onse# Better 2eedbac/ ●Better Deliverance ●Synchronized 1ork with other C)ea)onedD developer) Enough of the bore....... ●Ho1 do $et started3 ● - Hope you didn't )nooze yesterday ● +!# Subscribe to Mailing Lists ●Mentoring Progra') ●GsoC# Season of KDE, O2W Progra') ●Bootstra,pin$ Training Session) Strap yourself onto the Rocket ●And Blast O%%......... ● ● ● Entered A 4ormhole and Ea,ped into the KDE Galaxy ●No1 what? ●Pick a Planet to nhabit ●But....
    [Show full text]
  • Python and Epics: Channel Access Interface to Python
    Python and Epics: Channel Access Interface to Python Matthew Newville Consortium for Advanced Radiation Sciences University of Chicago October 12, 2010 http://cars9.uchicago.edu/software/python/pyepics3/ Matthew Newville (CARS, Univ Chicago) Epics and Python October 12, 2010 Why Python? The Standard Answers Clean Syntax Easy to learn, remember, and read High Level Language No pointers, dynamic memory, automatic memory Cross Platform code portable to Unix, Windows, Mac. Object Oriented full object model, name spaces. Also: procedural! Extensible with C, C++, Fortran, Java, .NET Many Libraries GUIs, Databases, Web, Image Processing, Array math Free Both senses of the word. No, really: completely free. Matthew Newville (CARS, Univ Chicago) Epics and Python October 12, 2010 Why Python? The Real Answer Scientists use Python. Matthew Newville (CARS, Univ Chicago) Epics and Python October 12, 2010 All of these tools use the C implementation of Python. NOT Jython (Python in Java) or IronPython (Python in .NET): I am not talking about Jython. Why Do Scientists Use Python? Python is great. The tools are even better: numpy Fast arrays. matplotlib Excellent Plotting library scipy Numerical Algorithms (FFT, lapack, fitting, . ) f2py Wrapping Fortran for Python sage Symbolic math (ala Maple, Mathematica) GUI Choices Tk, wxWidgets, Qt, . Free Python is Free. All these tools are Free (BSD). Matthew Newville (CARS, Univ Chicago) Epics and Python October 12, 2010 Why Do Scientists Use Python? Python is great. The tools are even better: numpy Fast arrays. matplotlib Excellent Plotting library scipy Numerical Algorithms (FFT, lapack, fitting, . ) f2py Wrapping Fortran for Python sage Symbolic math (ala Maple, Mathematica) GUI Choices Tk, wxWidgets, Qt, .
    [Show full text]
  • Qt Signals and Slots
    Qt Signals and Slots Olivier Goffart October 2013 About Me About Me QStyleSheetStyle Itemviews Animation Framework QtScript (porting to JSC and V8) QObject, moc QML Debugger Modularisation ... About Me Offering Qt help and services: Visit http://woboq.com C++ Code browser: http://code.woboq.org Outline 1 History 2 Pointer to member function 3 Lambda functions 4 New syntax in Qt5 5 Under The Hood Outline 1 History 2 Pointer to member function 3 Lambda functions 4 New syntax in Qt5 5 Under The Hood Qt 1.41 Qt 1.41 Qt 1.41 qobjectdefs.h Qt 2, Qt 3 Q PROPERTY No major changes in signals and slot Qt 4 Thread support QueuedConnection Meta type registration Several major internal changes Added file and line number information in debug mode But still no changes in the syntax How Does it Work? 1 bool connect(const QObject *sender, 2 const char *signal, 3 const QObject *receiver, 4 const char *member); How Does it Work? Compare the signature string to see if the arguments match Use the information provided my the moc to find the index of the signal and of the slot Keep in an internal map which signal is connected to what slots When emitting a signal, QMetaObject::activate is called. It calls qt metacall (generated by moc) with the slot index which call the actual slot 3 connect(socket,SIGNAL(infoReceived(const Info &)), 4 this,SLOT(slotInfoReceived(const MyFramework::Info &))); 6 connect(button3,SIGNAL(clicked()), 7 this,SLOT(buttonClicked(3))); 9 connect(comboBox,SIGNAL(valueChanged(int)), 10 settings ,SLOT(updateValue(QVariant))); 12 connect(model,SIGNAL(modelReset()),
    [Show full text]
  • RAND Suicide Prevention Program Evaluation TOOLKIT
    CHILDREN AND FAMILIES The RAND Corporation is a nonprofit institution that helps improve policy and EDUCATION AND THE ARTS decisionmaking through research and analysis. ENERGY AND ENVIRONMENT HEALTH AND HEALTH CARE This electronic document was made available from www.rand.org as a public service INFRASTRUCTURE AND of the RAND Corporation. TRANSPORTATION INTERNATIONAL AFFAIRS LAW AND BUSINESS Skip all front matter: Jump to Page 16 NATIONAL SECURITY POPULATION AND AGING PUBLIC SAFETY Support RAND SCIENCE AND TECHNOLOGY Purchase this document TERRORISM AND Browse Reports & Bookstore HOMELAND SECURITY Make a charitable contribution For More Information Visit RAND at www.rand.org Explore the RAND National Defense Research Institute View document details Limited Electronic Distribution Rights This document and trademark(s) contained herein are protected by law as indicated in a notice appearing later in this work. This electronic representation of RAND intellectual property is provided for non- commercial use only. Unauthorized posting of RAND electronic documents to a non-RAND website is prohibited. RAND electronic documents are protected under copyright law. Permission is required from RAND to reproduce, or reuse in another form, any of our research documents for commercial use. For information on reprint and linking permissions, please see RAND Permissions. This report is part of the RAND Corporation tool series. RAND tools may include models, databases, calculators, computer code, GIS mapping tools, practitioner guide- lines, web applications, and various toolkits. All RAND tools undergo rigorous peer review to ensure both high data standards and appropriate methodology in keeping with RAND’s commitment to quality and objectivity. RAND Suicide Prevention Program Evaluation TOOLKIT Joie D.
    [Show full text]
  • Kdesrc-Build Script Manual
    kdesrc-build Script Manual Michael Pyne Carlos Woelz kdesrc-build Script Manual 2 Contents 1 Introduction 8 1.1 A brief introduction to kdesrc-build . .8 1.1.1 What is kdesrc-build? . .8 1.1.2 kdesrc-build operation ‘in a nutshell’ . .8 1.2 Documentation Overview . .9 2 Getting Started 10 2.1 Preparing the System to Build KDE . 10 2.1.1 Setup a new user account . 10 2.1.2 Ensure your system is ready to build KDE software . 10 2.1.3 Setup kdesrc-build . 12 2.1.3.1 Install kdesrc-build . 12 2.1.3.2 Prepare the configuration file . 12 2.1.3.2.1 Manual setup of configuration file . 12 2.2 Setting the Configuration Data . 13 2.3 Using the kdesrc-build script . 14 2.3.1 Loading project metadata . 14 2.3.2 Previewing what will happen when kdesrc-build runs . 14 2.3.3 Resolving build failures . 15 2.4 Building specific modules . 16 2.5 Setting the Environment to Run Your KDEPlasma Desktop . 17 2.5.1 Automatically installing a login driver . 18 2.5.1.1 Adding xsession support for distributions . 18 2.5.1.2 Manually adding support for xsession . 18 2.5.2 Setting up the environment manually . 19 2.6 Module Organization and selection . 19 2.6.1 KDE Software Organization . 19 2.6.2 Selecting modules to build . 19 2.6.3 Module Sets . 20 2.6.3.1 The basic module set concept . 20 2.6.3.2 Special Support for KDE module sets .
    [Show full text]
  • Multi-Platform User Interface Construction – a Challenge for Software Engineering-In-The-Small
    Multi-platform User Interface Construction – A Challenge for Software Engineering-in-the-Small Judith Bishop Department of Computer Science University of Pretoria Pretoria 0002 South Africa [email protected] ABSTRACT The popular view of software engineering focuses on managing 1. INTRODUCTION teams of people to produce large systems. This paper addresses a 1.1 Software engineering different angle of software engineering, that of development for Software engineering as a discipline is perceived as tackling re-use and portability. We consider how an essential part of computing in-the-large. It elevates tools and techniques from the most software products – the user interface – can be successfully level of a craft, to where they can be efficiently and reproducibly engineered so that it can be portable across multiple platforms harnessed for the successful completion of large projects. and on multiple devices. Our research has identified the structure of the problem domain, and we have filled in some of Thirty years ago in 1975, Fred Brooks introduced us to the the answers. We investigate promising solutions from the mythical man month of software development [Brooks 1975] model-driven frameworks of the 1990s, to modern XML-based and followed this with the “no silver bullet” paper, in which he specification notations (Views, XUL, XIML, XAML), multi- talked about software engineering as being a process of building platform toolkits (Qt and Gtk), and our new work, Mirrors software with “specifications, assembly of components, and which pioneers reflective libraries. The methodology on which scaffolding” [Brooks 1987]. Boehm, too, found in 1976 that Views and Mirrors is based enables existing GUI libraries to be software engineering was, encouragingly, concentrating on the transported to new operating systems.
    [Show full text]