Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. QML and Qt Quick
  4. Is "font.bold: true" equal to "font.weight: Font.Bold" ?
Forum Updated to NodeBB v4.3 + New Features

Is "font.bold: true" equal to "font.weight: Font.Bold" ?

Scheduled Pinned Locked Moved Solved QML and Qt Quick
3 Posts 2 Posters 287 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.
  • R Offline
    R Offline
    RoachLin
    wrote on last edited by
    #1

    ChatGPT said yes, I just want to get further confirmation.

    1 Reply Last reply
    0
    • GrecKoG Offline
      GrecKoG Offline
      GrecKo
      Qt Champions 2018
      wrote on last edited by
      #2

      Yes, not that I would trust ChatGPT.

      When in doubt the easiest is to check the sources : https://github.com/qt/qtbase/blob/78a011b9ba01496ecfdd1cad1f651a89c4aa72e9/src/gui/text/qfont.h#L374

      inline void QFont::setBold(bool enable)
      { setWeight(enable ? Bold : Normal); }
      
      R 1 Reply Last reply
      4
      • GrecKoG GrecKo

        Yes, not that I would trust ChatGPT.

        When in doubt the easiest is to check the sources : https://github.com/qt/qtbase/blob/78a011b9ba01496ecfdd1cad1f651a89c4aa72e9/src/gui/text/qfont.h#L374

        inline void QFont::setBold(bool enable)
        { setWeight(enable ? Bold : Normal); }
        
        R Offline
        R Offline
        RoachLin
        wrote on last edited by
        #3

        @GrecKo Thanks for your reply!

        1 Reply Last reply
        0
        • R RoachLin has marked this topic as solved on

        • Login

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