Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. General talk
  3. Brainstorm
  4. The paintEvent() problem

The paintEvent() problem

Scheduled Pinned Locked Moved Brainstorm
licensingopen source
2 Posts 2 Posters 1.2k 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.
  • VRoninV Offline
    VRoninV Offline
    VRonin
    wrote on last edited by VRonin
    #1

    Hi everyone,
    Since there is no "legal" section of the forum I thought I could post here to hear your opinion.

    The problem in the title comes from the use I make 99% of the times of reimplementing a paint event for a widget. I normally just need to make small changes to the painting so, when reimplementing the event I just copy from the Qt sources the original code, paste it in my implementation and make the changes. Other times I basically copy the code from a paintEvent of a widget and reuse it for a delegate paint() method.

    Now my question is: can I use this in a closed source product linking the LGPL version of Qt without purchasing a commercial license?

    My gut feeling is no but then again why should I reinvent the wheel just to overcome a licensing detail?!

    Thanks in advance


    Edit:

    amended the linking line as it was misleading

    "La mort n'est rien, mais vivre vaincu et sans gloire, c'est mourir tous les jours"
    ~Napoleon Bonaparte

    On a crusade to banish setIndexWidget() from the holy land of Qt

    1 Reply Last reply
    1
    • tekojoT Offline
      tekojoT Offline
      tekojo
      wrote on last edited by
      #2

      @VRonin you probably need a software copyright layer to answer that :)

      My totally layman understanding (and now I take my work hat off, as this is code owned by my employer) is that in Finland (and probably most of the EU) you would be safe if the code you are copying is practically the only way to do it, and it is so simple that it is the only reasonable solution to your problem, and that the part you are copying is short enough that could simply re-write it anytime, and you aren't copy pasting anything else from the same work.

      The problem is that everything I'm saying above is way too hand-wavy to be of any use. It's always a case-by-case situation.

      Linking has nothing to do with it. It is a question of does the copy-pasted material automatically bring it's license with it to your code.

      If you wanted to be utterly safe, you would ask your friend, who has not seen the Qt code to implement a paintEvent once, and then use that. He probably would come up with about the same seven to ten lines of code. (clean room is the only way to be totally sure)

      1 Reply Last reply
      2

      • Login

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