Results 1 to 1 of 1

Thread: qpushbuttom text underlined on hover with stylesheet doesn't works.. ¿why?

  1. #1
    Join Date
    Jul 2009
    Posts
    74
    Thanks
    2
    Thanked 6 Times in 6 Posts

    Default qpushbuttom text underlined on hover with stylesheet doesn't works.. ¿why?

    Hi ¡ (sorry for my poor english)

    I’m trying to make a flat qpushbuttom looks like an hyperlink using stylesheets. I want that when I move the mouse inside the buttom (hover), the text should change his color and appears underlined. But… it doesn’t works !

    This is the stylesheet:

    css Code:
    1. QPushButton {
    2. font: 75 8pt "Tahoma";
    3. color: rgb(16, 37, 127);
    4. text-align: left;
    5. border: none;
    6. text-decoration: none;
    7. }
    8.  
    9. QPushButton:hover {
    10. color: rgb(116, 137, 127);
    11. text-decoration: underline;
    12. }
    To copy to clipboard, switch view to plain text mode 

    It’s very strange… because it changes the color… but not add the underline.

    Maybe… should I repaint the qpushbuttom dynamically when I hover it? how can I do this (how call for repaint a widget)?

    Thank you
    Last edited by wysota; 16th July 2009 at 16:53. Reason: reformatted to look better

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.