Skip to content

General and Desktop

This is where all the desktop OS and general Qt questions belong.
83.6k Topics 457.7k Posts
  • Fast Painting region by region

    2
    0 Votes
    2 Posts
    2k Views
    A
    For those who might be interested I figured out a simple way : Drawing outside the paint event in a picture with alpha enabled Painting the picture on top of the video. Which means before displaying the actual video, I paint the overlay image on the video image. Now I dropped superposition of child widgets and everything. The advantage is that I can create the overlay while the application is busy doing some other things.
  • How to properly store objects into a list

    13
    0 Votes
    13 Posts
    17k Views
    G
    As a side node, the crash comes from here: @ MyLine::MyLine(const MyLine &obj){ text = obj.text; startTime = obj.startTime; endTime = obj.endTime; } @ You copy the pointer. and in the destructor of both objects, you then destroy it (this and obj)
  • 0 Votes
    3 Posts
    2k Views
    A
    I guess you want to have your tabPostion at West.
  • QMainWindow Problem

    7
    0 Votes
    7 Posts
    4k Views
    G
    [quote author="ZapB" date="1310040148"]You need to use a more specific selector to ensure that only your QMainWindow selects that particular syle. Something like this stylesheet snippet should do it: @ QMainWindow { background-color: rgb(254, 255, 247); } @ You can set this directly on yoru mainwindow via the ui file. Just right-click on the main window in design mode of creator and select "Change Stylesheet..." and past the above in and hit Apply.[/quote] The reason why this is needed is that style sheets are also derived / forwarded to shildren. And you set the properties in a generic way.
  • [Solved] Painting in custom delegate

    4
    0 Votes
    4 Posts
    5k Views
    P
    this post is old, but not too much to say thank you! :D
  • Deep copy of a struct containing a QWidget*

    14
    0 Votes
    14 Posts
    8k Views
    J
    you could also use a QList<Field*> or a QVector<Field*> then you dont have to take care about copying. you can implement a destructor to delete the Widget in Field, and delete the field when you dont need it anymore
  • How can i add big size image in my toolbar window.??

    4
    0 Votes
    4 Posts
    3k Views
    M
    Thanks a lot for your i/p..
  • One QSqlTableModel, two different views

    9
    0 Votes
    9 Posts
    4k Views
    EddyE
    In Qt there is only qsortfilterproxymodel ... at this moment... ;) But other developers can make subclasses too. For instance when you program for kde. So in that sense the sentence is correct.
  • 0 Votes
    1 Posts
    2k Views
    No one has replied
  • Binary PList format

    6
    0 Votes
    6 Posts
    5k Views
    clogwogC
    nah, it's because another (iphone) application writes a binary plist file that i'm trying to read (via dropbox) so it can be read by windows and linux machines as well going into the qt sources won't help me much because in the platform limitations (http://doc.qt.nokia.com/stable/qsettings.html#platform-limitations) of QSettings it starts with: "On Mac OS X, the CFPreferences API used by QSettings expects..." so that CFPreferences API won't be available on non mac platforms. using ini files would have been great if i controlled the iphone application, but i don't. I'll have another look when i finish my mac version first. thanks all for thinking along. it's much appreciated !!
  • Resize dialog when it's child table resizes

    12
    0 Votes
    12 Posts
    8k Views
    Z
    If you are sure you want to go down this route then I think probably your best option is to subclass QTableView and override the sizeHint stuff so that the table returns sizehints suitable for the contents they are showing. The Qt layout system should then take care of the rest of it for you. That is not to say that calculating suitable size hints will be easy. You will need to query things like number of rows and their sizes (or are they all the same size), style metrics (since different styles have different size requirements), margins, font sizes etc.
  • QTableView or QTableWidget ?

    12
    0 Votes
    12 Posts
    22k Views
    H
    [quote author="Andre" date="1310028072"] Fine. So that works ok then? [/quote] Jepp, no problems. [quote] Yes, there is. Use ::setSelectionBehavior(QAbstractItemView::SelectRows) on your view. [/quote] Gracias.
  • [NOT SOLVED] Unable to set font of the widget derived from QPlainTextEdit

    14
    0 Votes
    14 Posts
    5k Views
    S
    I have a guess... I used Qt4SyntaxHighlighter that reads a css file and applies highlighting on the content. I didn't set any font in that css file (just colors). Is this related to syntax highlighter ?
  • Compilation Issue with QWS example

    18
    0 Votes
    18 Posts
    16k Views
    V
    Thank you Rahul Pandey. I ll give it a try n get back to u. Regards, Vijaeendra Simha
  • Copy .dll from .pro file [Solved]

    5
    0 Votes
    5 Posts
    9k Views
    L
    Thanks, but I mean a Qt define already defined by Qt framwork. I found this that do the works: @ QMAKE_POST_LINK = copy $${QMAKE_LIBDIR_QT}\Qt*.dll ..\bin @
  • How to use QProcess to open Safari on Mac

    3
    0 Votes
    3 Posts
    4k Views
    D
    Try with /Applications/Safari.app/Contents/MacOS/Safari
  • ShortCut doesn't work on MAC OS X

    2
    0 Votes
    2 Posts
    2k Views
    J
    are the function keys enabled on your keyboard? on mac you can switch between the function keys and the special tasks (like f12 is making sound louder) alternativly you can try QKeySequence(Qt::Shift + Qt::Key_F12)
  • [SOLVED] QTableWidgetItem no data only check flag

    6
    0 Votes
    6 Posts
    7k Views
    A
    I found solution I made my horizontal headers only digits in data role, and all text in tool tip role, but vertical header leave with text(because it's actually duplicates horizontal header) . So now it has a nice look. Andre, thanks for the help.
  • ReplayGain support in Phonon

    3
    0 Votes
    3 Posts
    2k Views
    J
    renato.filho renato.filho> Thanks for your answer, but I think you are talking about "repeat" function. I don't have any problems with that. I'm interested in "Replay Gain":http://en.wikipedia.org/wiki/Replay_Gain My current solution is to catch trackChanged signal (I will probably switch to finished() signal) and then I adjust the volume in dB according to Replay Gain values in tags.
  • Concept understanding on model view mechanism

    12
    0 Votes
    12 Posts
    5k Views
    U
    Thanks Andre and all to clearly the concept i guess i understand it fully now