Skip to content

Brainstorm

Stuck? Some ideas just need to be dumped on someone before they can materialize.
455 Topics 3.2k Posts
  • Is this a good case for a QStateMachine?

    4
    0 Votes
    4 Posts
    3k Views
    Z
    Hmmm, one way would be to provide a custom delegate (see [[Doc:QStyledItemDelegate]]) that knows about flashing.
  • [Moved] Run an application by double-clicking on the asociated file

    4
    0 Votes
    4 Posts
    3k Views
    G
    [quote author="hisoft" date="1314093113"]Hi, Thanks for replying. I didn't know that it's not Qt related as i hasn't any idea how to do it. I just started reading the articles you forwarded me to, and it seems to be what i'm looking for ![/quote] No problem, sometimes it's not clear where to post in the first place. We move stuff to the right forum then, nothing you must be worried about too much. If you've come to a solution, feel free to report back here. We'll be glad to hear that we could be of help.
  • [Moved] automatic run

    12
    0 Votes
    12 Posts
    5k Views
    R
    Yeah, I'll look into it once I decide to use such logging, thanks for the input.
  • Qt/Qt Designer (Version 3.x) GUI questions

    28
    0 Votes
    28 Posts
    15k Views
    L
    [quote author="qt-newbie" date="1313106592"]Loladiro, Thanks. I got the button text labels via the QAbstractButton class. Please explain where "queryInterface(nr)" is defined. I am a bit confused. Do I need to write a class/method for this ? Is it a wrapper ? Thanks, Qt-Newbie[/quote] Since I have no idea what kind of interface you have I just put it there to indicate where you have to query your interface.
  • Write into file

    11
    0 Votes
    11 Posts
    9k Views
    M
    And thus, the Muffincycle Party was born with the nomination of it's first candidate. :-)
  • [Moved] My application and it’s plugins

    2
    0 Votes
    2 Posts
    2k Views
    U
    Two years ago I asked myself the same question. My solution: getting the QtCreator source code and study it. QtCreator is exactly the kind of application you descibe in your post. It is very well designed and you can learn a lot from it - especially how to make a modular, plugin based application. Another good example for such a plugin based framework is the "Generic Component Framework":http://www.vcreatelogic.com/products/gcf/. You can use this framework out of the box without the need to design your own. Another great source for learning is the "Qtilities":http://www.qtilities.org/ library.
  • Exposing third-party API to QtScript

    1
    0 Votes
    1 Posts
    2k Views
    No one has replied
  • [SOLVED] (WINAPI!!!) Crash while render HBITMAP (Vista Glow)

    10
    0 Votes
    10 Posts
    7k Views
    S
    code works if I comment call of DrawThemeTextEx It draws may be need to set clipping before call it? OMG! @typedef HRESULT (*PDrawThemeTextEx)( HTHEME hTheme, HDC hdc, int iPartId, int iStateId, LPCWSTR pszText, int iCharCount, DWORD dwFlags, LPRECT pRect, const DTTOPTS *pOptions );@ I forget typedef WINAPI Should be @HRESULT (WINAPI *PDrawThemeTextEx)( HTHEME hTheme, HDC hdc, int iPartId, int iStateId, LPCWSTR pszText, int iCharCount, DWORD dwFlags, LPRECT pRect, const DTTOPTS *pOptions );@ All works!!! Thanks all PS. never ever copy-paste function declaration from MSDN!!!
  • [Moved] CSV File to XML File

    9
    0 Votes
    9 Posts
    7k Views
    G
    I moved this thread to the brainstorm forum, as it's only marginally Qt related.
  • [Moved] Help needed for SQL query

    10
    0 Votes
    10 Posts
    5k Views
    A
    [quote author="loladiro" date="1309941231"]Or something like this @SELECT a FROM (SELECT a, COUNT(DISTINCT b) as c a_b WHERE b IN(1,4) GROUP BY a HAVING c=2)@[/quote] Good, that's what I want.
  • [SOLVED] Generating a UI on the fly, Pt.2

    18
    0 Votes
    18 Posts
    8k Views
    V
    Thanks Andre. I think I know how I'll go about and design this.
  • Somebody for special coding in documentation for deprecated classes?

    11
    0 Votes
    11 Posts
    4k Views
    J
    If one is trying a use a class and looks at the documentation, it is quite obvious. I also understand that Qt documentation provides a list of "obsolete classes":http://doc.qt.nokia.com/4.7/obsoleteclasses.html each version. But unless you're constantly looking to keep the code up-to-date, you might not keep track of it. I usually compile the new version.. fire up assistant and continue working on the client's requirements. Maybe, it would be good to make that page more prominent and have a more in-your-face-visibility web page for it here on devnet. But then again, i don't see too many classes on the list. Anyhoo...
  • [SOLVED -- DON'T WASTE TIME ON THIS THREAD] Background Information

    5
    0 Votes
    5 Posts
    2k Views
    S
    Damnit, curiosity killed the cat again....
  • [SOLVED] Generating a UI on the fly

    20
    0 Votes
    20 Posts
    10k Views
    V
    Of course. I can post a screenshot as soon as I have something interesting.
  • QVector2D, QSizeF and QPointF : they all hold 2 floating point values

    6
    0 Votes
    6 Posts
    6k Views
    A
    I think maintainability is more important than you avoiding an if statement. It is hard to understand what piece of data is where if you use an array to store them. That may lead to bugs in Qt in the future. So please, don't. Adding a convenience function that implements operator is fine by me, but the implementation would basically look like FrankZ's proposal. I am not sure if adding a size to a point should yield another point, but perhaps it should. That would be easy to implement. You might want to supply a merge request containing the patch and a use case and/or other argumentation why this is needed.
  • Qt custom input method?

    2
    0 Votes
    2 Posts
    3k Views
    M
    Take a look at QInputContext, that's the plugin API you can use for your input method.
  • Cross platform IPC

    5
    0 Votes
    5 Posts
    8k Views
    Z
    You could use vortex http://www.aspl.es/vortex/doc.html its a BEEP Core protocol mapped into TCP/IP layer Some of its features are: Robust and well tested BEEP implementation with a threaded design (non-blocking parallel comunications), written in ANSI C. Context based API design making the library stateless. Support to run several ejecution contexts in the same process. A complete XML-RPC over BEEP RFC 3529 with a IDL/XDL protocol compiler (xml-rpc-gen). A complete TUNNEL (RFC3620) support. Complete implementation for TLS and SASL profiles. Modular design which allows to use only those components needed. Support to proxy BEEP connections through HTTP proxy servers. Support for single threaded (no async notification) programming. They even have a Javascript BEEP implementation. If you don't know what BEEP is. http://en.wikipedia.org/wiki/BEEP BEEP (Blocks Extensible Exchange Protocol) is a framework for creating network application protocols. It includes an application protocol kernel for connection-oriented asynchronous interactions, and can be used both for binary and text messages within the context of a single application user identity.[1] BEEP is intended to abstract-out the common features that have traditionally been duplicated in each protocol implementation. BEEP (formerly called BXXP) typically runs on top of TCP and allows the exchange of messages called 'frames'. Unlike HTTP (and similar protocols), either end of the connection can send a frame at any time, and 'questions' and 'replies' can be interleaved easily. BEEP also includes facilities for encryption and authentication, and is highly extensible. BEEP was designed by Marshall Rose, who also worked on the POP3, SMTP, and SNMP protocols.[2 It works on Windows, Mac, Linux
  • Original QMessageBox

    6
    0 Votes
    6 Posts
    3k Views
    A
    That's the whole point. You should try to avoid forbidding the user to do something just because it is convenient for you as a programmer. Instead, make actions undoable, for instance. Always keep in mind, that your user is trying to achieve something with your program. Your program is a tool, nothing more. That tool should support whatever the user is trying to do, and not hinder him in his way to do that. Popup boxes disrupt the flow of work, and of thought and focus of the user. They can also scare the user if you start giving warnings they may have trouble to comprehend. That hinders him in his task. So, rather than spending time on fancy graphics effects that are really the task of the window manager to handle anyway, I would suggest rather to spend your energy on making sure the user gets done what he want to get done without being bothered or scared by your application with such dialogs.
  • 0 Votes
    5 Posts
    3k Views
    A
    I am sorry, I am not deep enough into the issue to give you any advice on the actual contents on this discussion.
  • CanRead() and read()

    14
    0 Votes
    14 Posts
    6k Views
    D
    Looks like what is needed for OP is QTextStream::operator>>(). It reads one word from QIODevice (where words are separeted with QChar::isSpace() chars).