Grouping / Ungrouping of markup elements

Forum for the PDF-XChange Editor - Free and Licensed Versions

Moderators: PDF-XChange Support, Daniel - PDF-XChange, Chris - PDF-XChange, Sean - PDF-XChange, Paul - PDF-XChange, Vasyl - PDF-XChange, Ivan - Tracker Software, Stefan - PDF-XChange

olbob
User
Posts: 1
Joined: Wed Jun 24, 2015 8:34 am

Grouping / Ungrouping of markup elements

Post by olbob »

Hello folks,

with recent Versions of PDF XChange Editor a nice feature is gone: grouping and ungrouping of markups. The commands and buttons are still available (ID: cmd.group / cmd.ungroup), but without reaction.

Is it possible to reactivate them?
User avatar
Stefan - PDF-XChange
Site Admin
Posts: 19964
Joined: Mon Jan 12, 2009 8:07 am

Re: Grouping / Ungrouping of markup elements

Post by Stefan - PDF-XChange »

Hello olbob,

Welcome to our forums and thanks for the question.
I am not sure why this functionality has changed, so I've asked a colleague from the dev team to advise. As soon as I have some feedback I will post it here in this topic.

Regards,
Stefan
reyneer
User
Posts: 2
Joined: Fri Dec 15, 2017 10:30 am

Re: Grouping / Ungrouping of markup elements

Post by reyneer »

Hello,
I saw, that the "grouping of elements"-topic already exists and want to know if this issue solved in later versions. I currently use Version 6.0 Build 317.1.
Best regards,
Rainer
Willy Van Nuffel
User
Posts: 2921
Joined: Wed Jan 18, 2006 12:10 pm

Re: Grouping / Ungrouping of markup elements

Post by Willy Van Nuffel »

Indeed. "Group the selected objects" still exists in build 323.1, but still without result when applied.

Let us hear if Tracker Software Support can get some news about this ?

Best regards.
reyneer
User
Posts: 2
Joined: Fri Dec 15, 2017 10:30 am

Re: Grouping / Ungrouping of markup elements

Post by reyneer »

Ah, ok. Still unsolved :-(
Thanks for your answer.
User avatar
Patrick-Tracker Supp
Site Admin
Posts: 1645
Joined: Thu Mar 27, 2014 6:14 pm

Re: Grouping / Ungrouping of markup elements

Post by Patrick-Tracker Supp »

Hello reyneer,

Thank you for bringing this to our attention. I spoke with the dev team today about this and they hope to implement this for the next release in 2018.

Thank you for reviving this topic and informing us of this shortcoming!
Cheers!
If posting files to this forum, you must archive the files to a ZIP, RAR or 7z file or they will not be uploaded.
Thank you.

Cheers,

Patrick Charest
Tracker Support North America
User avatar
msg
User
Posts: 5
Joined: Tue Aug 02, 2016 1:52 pm

Re: Grouping / Ungrouping of markup elements

Post by msg »

Hey guys,
was just popping in on search to see whether this has been implemented. I'm still running v6.
I see that 7 is available.
Has object grouping been implemented yet? I'll make the jump to 7 if so.

Thanks!
User avatar
Daniel - PDF-XChange
Site Admin
Posts: 13315
Joined: Wed Jan 03, 2018 6:52 pm

Re: Grouping / Ungrouping of markup elements

Post by Daniel - PDF-XChange »

Hi MSG, we received your email, but for everyone else:

Grouping hasn't been implemented quite yet, though it is still on our list of todo's
Dan McIntyre - Support Technician
PDF-XChange Co. LTD

+++++++++++++++++++++++++++++++++++
Our Web site domain and email address has changed as of 26/10/2023.
https://www.pdf-xchange.com
[email protected]
cfessler
User
Posts: 33
Joined: Wed Apr 20, 2011 9:31 pm

Re: Grouping / Ungrouping of markup elements

Post by cfessler »

Hi there,

I was just looking for a grouping feature and found it. But it still seem not to work, right?

Is there any progress on it?

Kind regards
Christoph
spiceagent11
User
Posts: 2
Joined: Mon May 17, 2021 8:53 am

Re: Grouping / Ungrouping of markup elements

Post by spiceagent11 »

Indeed. "Group the selected objects" still exists in build 323.1, but still without result when applied.
Last edited by spiceagent11 on Sat Jun 26, 2021 2:39 am, edited 1 time in total.
User avatar
Stefan - PDF-XChange
Site Admin
Posts: 19964
Joined: Mon Jan 12, 2009 8:07 am

Re: Grouping / Ungrouping of markup elements

Post by Stefan - PDF-XChange »

Hello all,

Yes that is correct. There is such a command in the customization menus, but it is still not active, and even if you add it to a toolbar and click it - it does not work or do anything.

Kind regards,
Stefan
User avatar
Mathew
User
Posts: 952
Joined: Thu Jun 19, 2014 7:30 pm

Re: Grouping / Ungrouping of markup elements

Post by Mathew »

I just want to add my vote on this.
User avatar
Stefan - PDF-XChange
Site Admin
Posts: 19964
Joined: Mon Jan 12, 2009 8:07 am

Re: Grouping / Ungrouping of markup elements

Post by Stefan - PDF-XChange »

Hello Mathew,

Thank you for this! Appreciated and noted!

Kind regards,
Stefan
Eldereld
User
Posts: 7
Joined: Mon Dec 17, 2018 9:20 pm

Re: Grouping / Ungrouping of markup elements

Post by Eldereld »

I also just want to add my vote on this.
The Problem still exits.
Version 10.0.1 build 371

Kind Regards,
User avatar
Stefan - PDF-XChange
Site Admin
Posts: 19964
Joined: Mon Jan 12, 2009 8:07 am

Re: Grouping / Ungrouping of markup elements

Post by Stefan - PDF-XChange »

Hello Eldereld,

It is not a "problem" per se - however you are right that such a feature does not yet exist in our products.
It is still on the agenda, however I do not have an estimated build in which this is planned to be included yet. As soon as we have any further information - we will let everyone know!

Kind regards,
Stefan
luc.sohier
User
Posts: 2
Joined: Fri Feb 02, 2024 3:11 pm

Re: Grouping / Ungrouping of markup elements

Post by luc.sohier »

Hello to the team,

I would also like to express my interest in having this feature implemented. It seems that users have been requesting this functionality for a very long time now, as this thread dates back to 2015. It would be great to see some progress on this topic, as it could significantly improve the usability of the software.

Thank you in advance for considering this request :D

Merry christmas and happy new year to everybody!
User avatar
Dimitar - PDF-XChange
Site Admin
Posts: 2744
Joined: Mon Jan 15, 2018 9:01 am

Re: Grouping / Ungrouping of markup elements

Post by Dimitar - PDF-XChange »

luc.sohier wrote: ↑Mon Dec 16, 2024 7:58 am
Merry christmas and happy new year to everybody!
To you too.

Our developers are working on this.

Hopefully this feature will be implemented soon.
chalsmoncy
User
Posts: 1
Joined: Mon May 19, 2025 3:29 am

Re: Grouping / Ungrouping of markup elements

Post by chalsmoncy »

Wondering if this feature is available in version 10.60.0 build 396.
I would like to have markups/comments grouped (joined) and treated as a single markup.
Also, I would like to see a cloud markup with a callout feature.
User avatar
Stefan - PDF-XChange
Site Admin
Posts: 19964
Joined: Mon Jan 12, 2009 8:07 am

Re: Grouping / Ungrouping of markup elements

Post by Stefan - PDF-XChange »

Hello chalsmoncy,

Welcome to our forums!
Unfortunately no - Grouping is not yet available.

Kind regards,
Stefan
chrisplange
User
Posts: 2
Joined: Thu Mar 05, 2026 4:22 pm

Re: Grouping / Ungrouping of markup elements

Post by chrisplange »

Adding my vote to this. It would be extraordinarily helpful.
User avatar
Daniel - PDF-XChange
Site Admin
Posts: 13315
Joined: Wed Jan 03, 2018 6:52 pm

Grouping / Ungrouping of markup elements

Post by Daniel - PDF-XChange »

:)
Dan McIntyre - Support Technician
PDF-XChange Co. LTD

+++++++++++++++++++++++++++++++++++
Our Web site domain and email address has changed as of 26/10/2023.
https://www.pdf-xchange.com
[email protected]
TBS
User
Posts: 22
Joined: Mon Jan 05, 2026 2:52 pm

Re: Grouping / Ungrouping of markup elements

Post by TBS »

+1 vote for this
User avatar
Sean - PDF-XChange
Site Admin
Posts: 1444
Joined: Wed Sep 14, 2016 5:42 pm

Re: Grouping / Ungrouping of markup elements

Post by Sean - PDF-XChange »

:)
Sean Godley
Technical Writer
PDF-XChange Co LTD
Sales: +1 (250) 324-1621
Fax: +1 (250) 324-1623
Eldereld
User
Posts: 7
Joined: Mon Dec 17, 2018 9:20 pm

Re: Grouping / Ungrouping of markup elements

Post by Eldereld »

Liebes PDF-Xchange-Team,

die Anmerkungen / Posts zu dem Feature / Problem sind mittlerweile 9 !!! Jahre alt. Bitte seid so ehrlich, dass es nicht auf der Entwicklungsschiene eingestellt ist. Was schade ist.
Es würde gerade bei der Erstellung umfangreicher Skizzen eine starke Erleichterung sein.
User avatar
Sean - PDF-XChange
Site Admin
Posts: 1444
Joined: Wed Sep 14, 2016 5:42 pm

Re: Grouping / Ungrouping of markup elements

Post by Sean - PDF-XChange »

Hi Eldereld,

Please note that at any given moment, there are many thousands of feature requests/bug fixes that our development team are working through. If they deem this issue to be a high enough priority, they will get to it in good time. Thanks for your patience.

Kind regards,
Sean Godley
Technical Writer
PDF-XChange Co LTD
Sales: +1 (250) 324-1621
Fax: +1 (250) 324-1623
User avatar
Mathew
User
Posts: 952
Joined: Thu Jun 19, 2014 7:30 pm

Re: Grouping / Ungrouping of markup elements

Post by Mathew »

Based on javascript functionality, I'm sure there's development going on for this feature, and it will probably be a built-in feature soon.

But, to be on the cutting edge ;) the following script mostly* works in PXCE 10.6.1 (build 397) onwards. In PXCE 11 onwards it works quite well. It adds two buttons to the Edit menu (Classic toolbars) and under Home > Selection in the Ribbon U. Select the markups to group/ungroup then pick the menu item (it will be greyed out if nothing is selected)I:
image.png

Extract and save groupUngroup.js in the Javascripts folder. Detailed installation info here: viewtopic.php?p=196006#p196006
groupUngroup v0.2.zip
If you're using v10.7 of PXCE or earlier, the following may work better for you. It tries to work around the ungrouping problem by deleting and recreating the elements (so long as there's not a stamp in the group):
groupUngroup v0.3.zip

Limitations
  • It for sure does not work in PXCE 10.3 (build 386) or earlier.
  • On 10.7.6 (build 404) and probably earlier, the "ungroup" does not work properly in v0.2 (but the workaround in v0.3 is fine unless a stamp is in the group). It separates the elements, but it leaves them linked to one of them so if that one is deleted, they all will be deleted. This is because of a PXCE bug that prevents javascript from assigning a blank .inReplyTo property. You can see this in the comments pane after they are ungrouped, they still show as "Replies" to one of the markups:
    image(1).png
You do not have the required permissions to view the files attached to this post.
Last edited by Mathew on Tue Oct 06, 2026 2:26 am, edited 5 times in total.
Willy Van Nuffel
User
Posts: 2921
Joined: Wed Jan 18, 2006 12:10 pm

Re: Grouping / Ungrouping of markup elements

Post by Willy Van Nuffel »

Thanks very much for this javascript @Mathew.

It works like promised.

Kind regards.
User avatar
Sean - PDF-XChange
Site Admin
Posts: 1444
Joined: Wed Sep 14, 2016 5:42 pm

Re: Grouping / Ungrouping of markup elements

Post by Sean - PDF-XChange »

:)
Sean Godley
Technical Writer
PDF-XChange Co LTD
Sales: +1 (250) 324-1621
Fax: +1 (250) 324-1623
WeHavePizzaAtHome
User
Posts: 5
Joined: Wed Feb 04, 2026 6:17 pm

Re: Grouping / Ungrouping of markup elements

Post by WeHavePizzaAtHome »

Hello,

As any custom Java must be loaded / installed by the IT department, hoping that grouping in the official release will come someday.
User avatar
Sean - PDF-XChange
Site Admin
Posts: 1444
Joined: Wed Sep 14, 2016 5:42 pm

Re: Grouping / Ungrouping of markup elements

Post by Sean - PDF-XChange »

Hi WeHavePizzaAtHome,

We do hope to add this in the future too.

Kind regards,
Sean Godley
Technical Writer
PDF-XChange Co LTD
Sales: +1 (250) 324-1621
Fax: +1 (250) 324-1623
else
User
Posts: 4
Joined: Sun Jun 10, 2018 3:54 pm

Re: Grouping / Ungrouping of markup elements

Post by else »

Thank you very much for this JavaScript, @Mathew.
It works perfectly.
Features like this have become indispensable in a PDF editor!
Best regards, else
User avatar
Sean - PDF-XChange
Site Admin
Posts: 1444
Joined: Wed Sep 14, 2016 5:42 pm

Re: Grouping / Ungrouping of markup elements

Post by Sean - PDF-XChange »

:)
Sean Godley
Technical Writer
PDF-XChange Co LTD
Sales: +1 (250) 324-1621
Fax: +1 (250) 324-1623
Eldereld
User
Posts: 7
Joined: Mon Dec 17, 2018 9:20 pm

Re: Grouping / Ungrouping of markup elements

Post by Eldereld »

The implementation of grouping/ungrouping markup elements works very well and is a great help. Thank you very much!

While testing, I noticed some functionality that I would still like to see improved.

When either cmd.tool.hand or cmd.tool.editAnnots is active, selecting the "master" annotation also displays the bounding box around the group. However, this does not happen when selecting one of the slave annotations. It would be helpful if it did.

If you want to change the properties of all annotations in a group, you still have to select the annotations individually.

When either cmd.tool.hand or cmd.tool.editAnnots is active, selecting two annotations belonging to two or more different groups causes all annotations in those groups to be selected, allowing their properties to be changed simultaneously. This is a positive feature.

Is there a trick to selecting all annotations in a group simply by selecting one annotation belonging to that group?

I would like to know how to achieve this both when working directly in PDF-XChange Editor and through a JavaScript script. In JavaScript, this.selectedAnnots is read-only. Is there a workaround for this discussed elsewhere on the forum?

Best regards
User avatar
Sean - PDF-XChange
Site Admin
Posts: 1444
Joined: Wed Sep 14, 2016 5:42 pm

Re: Grouping / Ungrouping of markup elements

Post by Sean - PDF-XChange »

Hi Eldereld,

I've passed this to the developmen team for review. In the future, please use English when posting in the forum.

Kind regards,
Sean Godley
Technical Writer
PDF-XChange Co LTD
Sales: +1 (250) 324-1621
Fax: +1 (250) 324-1623
User avatar
Mathew
User
Posts: 952
Joined: Thu Jun 19, 2014 7:30 pm

Re: Grouping / Ungrouping of markup elements

Post by Mathew »

Eldereld wrote: ↑Thu Nov 19, 2026 10:29 am Is there a trick to selecting all annotations in a group simply by selecting one annotation belonging to that group?

I would like to know how to achieve this both when working directly in PDF-XChange Editor and through a JavaScript script. In JavaScript, this.selectedAnnots is read-only. Is there a workaround for this discussed elsewhere on the forum?

Best regards
As you can see, there's a lot involved with making grouping work well. I'm sure that there is ongoing work -- it seems to work better in each release. As far as javascript is concerned, I can answer that:

To pick up all of the annotations in a group, one could do something like this:

Code: Select all

/** get all the annotations in a group
  * @param {array} selAnns - the selected annotations
  * @returns {array} - the selected annotations plus all annotations that are part of the group
**/

function getAllGrouped(selAnns = []) {
  // using a set so don't have to worry about adding multiple times
  const allAnns = new Set();
  
  // to cache all the annotations for current page
  const pageAnns = new Map();
  // get all other annotations that are part of this group
  const getGroup = (annot) => {
    // this may be the primary annotation
    const name = ("Group" === annot.refType) ? annot.inReplyTo : annot.name;
    const {page,doc} = annot;
    
    // cache all the annotations on the current page (groups cannot include annotations on other pages)
    if (!pageAnns.has(page)) {
      pageAnns.set(page, doc.getAnnots(page));
    }
    // get whole group (doesn't work in build 404 because inReplyTo is '' when refType==Group)
    return pageAnns.get(page)
      .filter(a => a.name === name || ("Group" === a.refType && a.inReplyTo === name));
  };

  for (const ann of selAnns) {
    // now deal with group
    getGroup(ann).forEach(an => allAnns.add(an));
  }
  return [...allAnns];
}

// use the function on all selected annotations
//  and make list of the names of them including all group members
getAllGrouped(this.selectedAnnots).map(a => a.name);
Last edited by Mathew on Thu Nov 19, 2026 6:51 pm, edited 2 times in total.
User avatar
Sean - PDF-XChange
Site Admin
Posts: 1444
Joined: Wed Sep 14, 2016 5:42 pm

Re: Grouping / Ungrouping of markup elements

Post by Sean - PDF-XChange »

Hi Mathew,

Thanks for the input here.

Kind regards,
Sean Godley
Technical Writer
PDF-XChange Co LTD
Sales: +1 (250) 324-1621
Fax: +1 (250) 324-1623