Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. How do i make my text in QStandardItem to link to open default browser?

How do i make my text in QStandardItem to link to open default browser?

Scheduled Pinned Locked Moved General and Desktop
2 Posts 2 Posters 1.9k Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • U Offline
    U Offline
    umen242
    wrote on last edited by
    #1

    Im using QStandardItem as my model items . i was reading about QStyledItemDelegate to manipulate the item's but im not sure it the right answer to my problem . and if it is .
    how should my paint method should look like to be able me to make the text clickable
    and open the pc default browser with a link

    1 Reply Last reply
    0
    • D Offline
      D Offline
      dakron
      wrote on last edited by
      #2

      One of the possible solutions is to handle the click event properly and use the QDesktopServices::openUrl() with the text from your item.

      1 Reply Last reply
      0

      • Login

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • Users
      • Groups
      • Search
      • Get Qt Extensions
      • Unsolved