Search Results

Search found 2964 results on 119 pages for 'qt stylesheet'.

Page 9/119 | < Previous Page | 5 6 7 8 9 10 11 12 13 14 15 16  | Next Page >

  • QT clicked signal dosnt work on QStandardItemModel with tree view

    - by user63898
    Hello i have this code in QT and all i want to to catch the clicked event when some one clicking in one of the treeview rows without success here is my code: (parant is the qMmainwindow) m_model = new QStandardItemModel(0, 5, parent); // then later in the code i have proxyModel = new QSortFilterProxyModel; proxyModel->setDynamicSortFilter(true); setSourceModel(createMailModel(parent)); ui.treeView->setModel(proxyModel); ui.treeView->setSortingEnabled(true); ui.treeView->sortByColumn(4, Qt::DescendingOrder); // and my signal/slot looks like this but its not working //and im not getting eny clicked event fired connect(ui.treeView,SIGNAL(Clicked(const QModelIndex& ) ), this,SLOT( treeViewSelectedRow(const QModelIndex& ) ) ); also how can i debug QT signal/slots so i can see some debug massages printing when something is wrong ?

    Read the article

  • Implementing Qt File Dialog with a Different File System Library (boost)

    - by knight
    Hi, I am writing an application which requires me to use another file system and file engine handlers and not the qt's default ones. Basically what I want to be able to do is to use qt's file dialog but have an underlying file system handler (for example built using boost file system library) of mine handling all the operations with regards to file and directory operations within that dialog. I have already written a custom file engine which handles some of the operations but I am now stuck with Qt's file system model and the file system watcher engine, as I need to have the signals transmitted for this custom file engine. Seems like I have a daunting task ahead. Am I heading in the right direction? Is there any other simpler way that I could implement this? Can anyone give me any idea on how to proceed. I was thinking of looking into proxy models but not sure if that would work. Thanks in advance for any help.

    Read the article

  • Qt C++ signals and slots did not fire

    - by Xegara
    I have programmed Qt a couple of times already and I really like the signals and slots feature. But now, I guess I'm having a problem when a signal is emitted from one thread, the corresponding slot from another thread is not fired. The connection was made in the main program. This is also my first time to use Qt for ROS which uses CMake. The signal fired by the QThread triggered their corresponding slots but the emitted signal of my class UserInput did not trigger the slot in tflistener where it supposed to. I have tried everything I can. Any help? The code is provided below. Main.cpp #include <QCoreApplication> #include <QThread> #include "userinput.h" #include "tfcompleter.h" int main(int argc, char** argv) { QCoreApplication app(argc, argv); QThread *thread1 = new QThread(); QThread *thread2 = new QThread(); UserInput *input1 = new UserInput(); TfCompleter *completer = new TfCompleter(); QObject::connect(input1, SIGNAL(togglePause2()), completer, SLOT(toggle())); QObject::connect(thread1, SIGNAL(started()), completer, SLOT(startCounting())); QObject::connect(thread2, SIGNAL(started()), input1, SLOT(start())); completer->moveToThread(thread1); input1->moveToThread(thread2); thread1->start(); thread2->start(); app.exec(); return 0; } What I want to do is.. There are two seperate threads. One thread is for the user input. When the user enters [space], the thread emits a signal to toggle the boolean member field of the other thread. The other thread 's task is to just continue its process if the user wants it to run, otherwise, the user does not want it to run. I wanted to grant the user to toggle the processing anytime that he wants, that's why I decided to bring them into seperate threads. The following codes are the tflistener and userinput. tfcompleter.h #ifndef TFCOMPLETER_H #define TFCOMPLETER_H #include <QObject> #include <QtCore> class TfCompleter : public QObject { Q_OBJECT private: bool isCount; public Q_SLOTS: void toggle(); void startCounting(); }; #endif tflistener.cpp #include "tfcompleter.h" #include <iostream> void TfCompleter::startCounting() { static uint i = 0; while(true) { if(isCount) std::cout << i++ << std::endl; } } void TfCompleter::toggle() { // isCount = ~isCount; std::cout << "isCount " << std::endl; } UserInput.h #ifndef USERINPUT_H #define USERINPUT_H #include <QObject> #include <QtCore> class UserInput : public QObject { Q_OBJECT public Q_SLOTS: void start(); // Waits for the keypress from the user and emits the corresponding signal. public: Q_SIGNALS: void togglePause2(); }; #endif UserInput.cpp #include "userinput.h" #include <iostream> #include <cstdio> // Implementation of getch #include <termios.h> #include <unistd.h> /* reads from keypress, doesn't echo */ int getch(void) { struct termios oldattr, newattr; int ch; tcgetattr( STDIN_FILENO, &oldattr ); newattr = oldattr; newattr.c_lflag &= ~( ICANON | ECHO ); tcsetattr( STDIN_FILENO, TCSANOW, &newattr ); ch = getchar(); tcsetattr( STDIN_FILENO, TCSANOW, &oldattr ); return ch; } void UserInput::start() { char c = 0; while (true) { c = getch(); if (c == ' ') { Q_EMIT togglePause2(); std::cout << "SPACE" << std::endl; } c = 0; } } Here is the CMakeLists.txt. I just placed it here also since I don't know maybe the CMake has also a factor here. CMakeLists.txt ############################################################################## # CMake ############################################################################## cmake_minimum_required(VERSION 2.4.6) ############################################################################## # Ros Initialisation ############################################################################## include($ENV{ROS_ROOT}/core/rosbuild/rosbuild.cmake) rosbuild_init() set(CMAKE_AUTOMOC ON) #set the default path for built executables to the "bin" directory set(EXECUTABLE_OUTPUT_PATH ${PROJECT_SOURCE_DIR}/bin) #set the default path for built libraries to the "lib" directory set(LIBRARY_OUTPUT_PATH ${PROJECT_SOURCE_DIR}/lib) # Set the build type. Options are: # Coverage : w/ debug symbols, w/o optimization, w/ code-coverage # Debug : w/ debug symbols, w/o optimization # Release : w/o debug symbols, w/ optimization # RelWithDebInfo : w/ debug symbols, w/ optimization # MinSizeRel : w/o debug symbols, w/ optimization, stripped binaries #set(ROS_BUILD_TYPE Debug) ############################################################################## # Qt Environment ############################################################################## # Could use this, but qt-ros would need an updated deb, instead we'll move to catkin # rosbuild_include(qt_build qt-ros) rosbuild_find_ros_package(qt_build) include(${qt_build_PACKAGE_PATH}/qt-ros.cmake) rosbuild_prepare_qt4(QtCore) # Add the appropriate components to the component list here ADD_DEFINITIONS(-DQT_NO_KEYWORDS) ############################################################################## # Sections ############################################################################## #file(GLOB QT_FORMS RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} ui/*.ui) #file(GLOB QT_RESOURCES RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} resources/*.qrc) file(GLOB_RECURSE QT_MOC RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} FOLLOW_SYMLINKS include/rgbdslam_client/*.hpp) #QT4_ADD_RESOURCES(QT_RESOURCES_CPP ${QT_RESOURCES}) #QT4_WRAP_UI(QT_FORMS_HPP ${QT_FORMS}) QT4_WRAP_CPP(QT_MOC_HPP ${QT_MOC}) ############################################################################## # Sources ############################################################################## file(GLOB_RECURSE QT_SOURCES RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} FOLLOW_SYMLINKS src/*.cpp) ############################################################################## # Binaries ############################################################################## rosbuild_add_executable(rgbdslam_client ${QT_SOURCES} ${QT_MOC_HPP}) #rosbuild_add_executable(rgbdslam_client ${QT_SOURCES} ${QT_RESOURCES_CPP} ${QT_FORMS_HPP} ${QT_MOC_HPP}) target_link_libraries(rgbdslam_client ${QT_LIBRARIES})

    Read the article

  • Compiling Qt for Windows 98

    - by wrp
    I need to support Windows 98. The Qt documentation claims this is possible, but there are no instructions. The distributed binaries don't run on Win98 and the majority of Qt applications I have sampled also don't. For several apps that do run on 98, I have asked authors how they did it, but the common answer is that it was accidental and they don't know what factors caused it. In searching the forums for help, I found only guesses that turned out to be wrong. For example, one belief is that to compile for Win9x, you must build the tools and the apps on that platform. Yet, things I found to run were built on newer versions of Windows. What is required to build the Qt dev tools and then applications for Win98? How about cross-compiling from WinXP or Linux? Are there specific components that can't be made to run on Win98? Are there particular difficulties with dynamic or static linking for Win98 support?

    Read the article

  • Qt Direct Connection

    - by user152508
    Hello I have created Qt tree control( and its nodes ) in different thread than the main thread. In the main thread I want to show context menu for the clicked node, so I am connectiong the actions in the menu with appropriate slots in the main thread. The connect function returns true , but slot is never executed. If I explicitly say in connect function that this is Qt :: DirectConnection then everything works fine. Why is this ? I I create my tree in main thread, everything also works fine , without having to say that this is Qt::DirectConnection .

    Read the article

  • Qt/C++ event loop exception handling

    - by Georg
    I am having an application heavily based on QT and on a lot of third party libs. THese happen to throw some exceptions in several cases. In a native Qt App this causes the application to abort or terminate. Often the main data model is still intact as I am keeping it in pure Qt with no external data. So I am thinking that I could also just recover by telling the user that there has occured an error in this an that process and he should save now or even decide to continue working on the main model. Currently the program jsut silently exits without even telling a story. Please help.

    Read the article

  • Qt drag/drop: cannot move when copy is enabled (Ubuntu Gnome)

    - by Scott
    I'm implementing a view and a model where I want to support both moving items internally (by dragging), and copying items (by pressing Ctrl while dragging). I've done everything I need to do according to the instructions. I've set up the mime functions, I've implemented removeRows(), and flags(). The problem is when I drag, it defaults to a copy operation (I get the arrow cursor with a plus sign, and it indeed copies the item by creating a new one in the model). The only difference I can see is this: If I return only Qt::MoveAction in supportedDropActions(), it only moves. If I return (Qt::CopyAction | Qt::MoveAction), it only copies. Any ideas? I want it to work like files in Nautilus (Gnome) or Windows file Explorer: drag moves icons around, ctrl+drag copies them.

    Read the article

  • Livre blanc de l'outillage de Qt Quick, traduit par Thibaut Cuvelier et Louis du Verdier

    Qt Quick correspond à une collection de technologies qui sont conçues pour aider les développeurs à créer des interfaces utilisateur intuitives, fluides et à l'apparence moderne, le genre d'interfaces graphiques de plus en plus utilisées sur les téléphones portables, lecteurs média, set-top boxes et autres appareils portables. Qt Quick est constitué d'un ensemble riche d'éléments d'interface utilisateur, d'un langage déclaratif pour la représentation d'interfaces utilisateur, et d'un moteur d'exécution de langage. Une collection d'API C++ est utilisée pour intégrer ces caractéristiques de haut niveau avec les applications Qt classiques. La version 2.1 de l'environnement de développement (EDI) Qt Creator introduit des outils utiles au développement d'applications Qt Quick. Ce livre blanc do...

    Read the article

  • Sortie de Qt 5 RC, avec une restructuration de la documentation

    Sortie de Qt 5 alpha La première version majeure du Qt Project autonome se concentre sur les performances et les capacités graphiques La version 5 de Qt vient de sortir en version alpha. Cette version est la première version majeure depuis que Qt est devenu autonome avec la création du Qt Project. Beaucoup de personnes ont contribué à cette nouvelle version, pas uniquement des développeurs de chez Nokia. Les différents modules ont été regroupés en deux catégories, les essentiels, installés par défaut, et les add-ons, installés à la demande. L'objectif de cette version alpha est de récupérer les retours des utilisateurs, principalement sur les modules essentiels. Lars Knoll, le responsable...

    Read the article

  • Première préversion de Qt 4.7.0 et de Qt Creator 2.0 : première intégration de la technologie d'inte

    Bonjour, Vous avez sûrement entendu parler de la dernière version beta de Qt, la 4.6 beta 1. Vous l'attendez certainement, autant que l'enfant en décembre attend l'arrivée du Père Noël et des cadeaux. Les cadeaux seront nombreux cette année : Qt 4.6 devrait sortir vers cette période, et nous devrions avoir de plus amples informations sur Qt 4.7. Les ingénieurs de Qt pensaient adopter une nouvelle convention de nommage. Cependant, même si les noms proposés étaient imaginatifs, ils ne représentaient pas ce qu'est Qt 4.7 : il s'agit d'améliorations du coeur du framework. Qu'attend-t-on principalement de ce nouveau ...

    Read the article

  • Sortie de Qt 5 beta, cette préversion montre l'achèvement de la modularisation du framework

    Sortie de Qt 5 alpha La première version majeure du Qt Project autonome se concentre sur les performances et les capacités graphiques La version 5 de Qt vient de sortir en version alpha. Cette version est la première version majeure depuis que Qt est devenu autonome avec la création du Qt Project. Beaucoup de personnes ont contribué à cette nouvelle version, pas uniquement des développeurs de chez Nokia. Les différents modules ont été regroupés en deux catégories, les essentiels, installés par défaut, et les add-ons, installés à la demande. L'objectif de cette version alpha est de récupérer les retours des utilisateurs, principalement sur les modules essentiels. Lars Knoll, le responsable...

    Read the article

  • Qt Mobility disponible en version 1.1.1, avec améliorations du binding Qt Quick et des performances sur Symbian

    Qt Mobility disponible en version 1.1.1 Avec améliorations du binding Qt Quick et des performances sur Symbian Mise à jour du 02/03/2011 par dourouc05 Le Qt Mobility nouveau est arrivé. Il ne s'agit que d'une version de maintenance, n'apportant « que » des améliorations au niveau du binding Qt Quick et des améliorations de performances, principalement en ce qui concerne Symbian, sans oublier les habituelles corrections de bogues, améliorations de la documentation et des tests. Cette nouvelle version, la 1.1.1, est aussi incluse dans la nouvelle version du Qt SDK, la beta. Un certain nombre de bogues de priorité important...

    Read the article

  • What are the statuses in terms of popularity and ease of use for Qt's Webkit and Wt? [closed]

    - by Holland
    Are web frameworks like Wt and Qt's Webkit becoming a viable opportunity for C++ programmers to step into server side development for web applications through combining client-side JavaScript code with HTML/CSS and C++ for the backend? Disclaimer This is not to start a language holy war, with floods of opinions on why this or that is better, or shouldn't be used to produce web applications. I am merely looking for information in regards to these two frameworks, in terms of experience from people who have used these before and would be able to comment on it.

    Read the article

  • how to write high quality GUI software with qt?

    - by Opetmar
    I want to write a project using QT library, so after learning the library and mastering it how should I start, what other libraries or things that I should learn? are there any other tools that will help me during the development or tools well help the end user to install the software and using it? What are the things that I should be aware? what are the things that I should avoid so it can run efficiently?

    Read the article

  • Qt 4.6 OpenGL GLSL

    - by Zeke
    I'm trying to find like NeHe's tutorials for Qt that are all in GLSL. Because lets face it, OpenGL in the old days are dead and Shaders are the only way now. And with Qt-4.6 they introduced the QMatrix4x4, QVector3, and the Shader classes. But I cannot find any tutorials for this. All the ones I do find, all use crappy SDL and/or GLUT (Which are just plain useless).

    Read the article

  • Best json parser for qt?

    - by Martin
    I'm using QT for Symbian and need a simple json parser. I need to be able to go from json to Qt-variant and the other way around. Is there a simple json parser that I can use? I don't want to write my own. What is the best way to go? Thanks!

    Read the article

  • Fact or fiction: Webkit’s rendering performance is much lower when used in Qt

    - by Jen
    Using Qt’s Webkit implementation renders much slower than directly implementing the Webkit engine -- is this true or just a myth? From my own experience, I found the load time of a complex page about twice as long in Qt’s “Fancy Browser” example as it does in Google Chrome (which also incorporates a port of Webkit), but I hardly think that is a fair comparison. Any insights on this?

    Read the article

  • How to save webpage in QT webkit as "save as complete webpage"

    - by kokila
    Hello, I need to save web page using QT webkit similar to "Save as complete webpage". Following are my requirements, Save the index html file, maintaining entity encoding. Need to download all linked images and other resources. Need to change resource path in html page to local downloaded path. Need to maintain webpage current state. I can use QT and javascript to do this. Please provide me some inputs on this. Thanks

    Read the article

  • Accessing not Non-QObject-based objects from Qt Script

    - by uni
    Is there any nice and simple way to access non QObject-based classes, such as QXmlQuery, QDateTime etc. from Qt Script? The only way I see is to wrap QXmlQuery in another class that inherits QObject and declare as slot every function which I need to access from Qt Script: void MyXmlQuery::setQuery ( const QString & sourceCode, const QUrl & documentURI ) { realxmlquery_.setQuery(sourceCode, documentURI); }

    Read the article

  • using graphviz with qt

    - by radi
    hi , i have a compiler project and i want to print the ast after the compile complete so can i print this ast to qt (on c++) panel using graphviz ? note : i dont know if there is a binding between qt or c++ and graphviz , so if it doesnt work please help me to find the alternative . thanks .

    Read the article

  • Serialization with Qt

    - by Narek
    I am programming a GUI with Qt. In my GUI I have a huge std::map. And "MyType" is a class that has different kinds of filds. So, in a word, I want to serialize the std::map. How can I do that? Does Qt provides us with neccesary features? P.S. I would like to use std::map, NOT QMap.

    Read the article

  • Best C# bindings for Qt?

    - by Stefan Monov
    I've written a game in C# with SDL.NET and OpenGL. I want to add a menu to it, for which I need Qt. What bindings do you recommend for Qt in C#? Qyoto? qt4dotnet? other? Requirements: fast should just work and be polished - i.e. no weird problems at every step integration with the buildsystem, uic, resources, etc, should work well

    Read the article

  • QT vs. Net - REAL comparisons for R.A.D. projects

    - by Pirate for Profit
    Man in all these Qt vs. .NET discussions 90% these people argue about the dumbest crap. Trying to get a real comparison chart here, because I know a little about both frameworks but I don't know everything. I believe Qt and .NET both have strengths and weaknesses. This is to make a comparison that highlights these so people can make more informed decisions before embarking on a project, in the spirit of R.A.D. Event Handling In Qt the event handling system is very simple. You just emit signals when something cool happens and then catch them in slots. ie. // run some calculations, then emit valueChanged(30, false, 20.2); and then catching it, any object can make a slot to recieve that message easily void MyObj::valueChanged(int percent, bool ok, float timeRemaining). It's easy to "block" an event or "disconnect" when needed, and works seamlessly across threads... once you get the hang of it, it just seems a lot more natural and intuitive than the way the .NET event handling is set up (you know, void valueChanged(object sender, CustomEventArgs e). And I'm not just talking about syntax, because in the end the .NET anonymous delegates are the bomb. I'm also talking about in more than just reflection (because, yes, .NET obviously has much stronger reflection capabilities). I'm talking about in the way the system feels to a human being. Qt wins hands down for the simplest yet still flexible event handling system ever i m o. Plugins and such I do love some of the ease of C# compared to C++, as well as .NET's assembly architecture, even though it leads to a bunch of .dll's (there's ways to combine everything into a single exe though). That is a big bonus for modular projects, which are a PITA to import stuff in C++ as far as RAD is concerned. Database Ease of Doing Crap Also what about datasets and database manipulations. I think .net wins here but I'm not sure. Threading/Conccurency How do you guys think of the threading? In .NET, all I've ever done is make like a list of master worker threads with locks. I like QConcurrentFramework, you don't worry about locks or anything, and with the ease of the signal slot system across threads it's nice to get notified about the progress of things. QConcurrent is the simplest threading mechanism I've ever played with. Memory Usage Also what do you think of the overall memory usage comparison. Is the .NET garbage collector pretty on the ball and quick compared to the instantaneous nature of native memory management? Or does it just let programs leak up a storm and lag the computer then clean it up when it's about to really lag? Doesn't the just-in-time compiler make native code that is pretty good, like and that only happens the first time the program is run? However, I am a n00b who doesn't know what I'm talking about, please school me on the subject.

    Read the article

  • How strict to be when using Qt framework?

    - by toffeehoops
    I'm building a Qt application that needs to use libssh, a SSH client library. libssh (understandably) performs its own network connections, however Qt has its own infrastructure for network connections (QTcpSocket etc). Should I worry about these differences? Should I be trying to make libssh make network connections via QTcpSocket... Or if it works fine on the platforms I'm targeting, is that good enough?

    Read the article

< Previous Page | 5 6 7 8 9 10 11 12 13 14 15 16  | Next Page >