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. Transfering QTextDocument's contents to another
Qt 6.11 is out! See what's new in the release blog

Transfering QTextDocument's contents to another

Scheduled Pinned Locked Moved General and Desktop
3 Posts 2 Posters 1.6k Views 1 Watching
  • 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.
  • ? Offline
    ? Offline
    A Former User
    wrote on last edited by
    #1

    Hi,

    I want to transfer all the contents of a QTextDocument to another, including all the existing resources.

    Any idea ?

    Thanks.

    1 Reply Last reply
    0
    • JeroentjehomeJ Offline
      JeroentjehomeJ Offline
      Jeroentjehome
      wrote on last edited by
      #2

      QTextDocument::clone

      Might that be what you want??

      Greetz, Jeroen

      1 Reply Last reply
      0
      • ? Offline
        ? Offline
        A Former User
        wrote on last edited by
        #3

        I'm not trying to clone the document but to insert all its content into another.
        For example :
        Let's assume that the first document is structured as follow :
        @
        <Document1>
        <RootFrame1>
        <Block1 />
        <Frame1 />
        <Table1/>
        <Frame2 />
        <Block2 />
        ...
        </Document1>
        @

        and the second one :
        @
        <Document2>
        <RootFrame2>
        HERE WILL INSERT ALL THE CONTENT OF THE FIRST DOCUMENT
        </Document2>
        @

        After transfering contents, the second document shall look like :
        @
        <Document2>
        <RootFrame2>
        <Document1>
        <RootFrame1>
        <Block1 />
        <Frame1 />
        <Table1/>
        <Frame2 />
        <Block2 />
        ...
        </Document1>
        </Document2>
        @

        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