Page 1 of 1

IPXV_DocSelChangedEvent / IPXV_DocSelection / Cluster

Posted: Thu May 13, 2021 2:53 pm
by zarkogajic
Hi Support,

What is "Cluster" in IPXV_DocSelection ?

And (I guess related):

ClusterID in IUIX_Layout

GetSelCluster in IPXV_Document

-žarko

Re: IPXV_DocSelChangedEvent / IPXV_DocSelection / Cluster

Posted: Tue May 18, 2021 6:40 pm
by Vasyl-Tracker Dev Team
Hi žarko.

About IPXV_DocSelection::ClusterID. Editor has many types of selections in UI: selection of comments, content(s) selection, bookmark(s) selection, link(s) selection, etc. So user may select bookmarks in Bookmarks pane then he also may select some comments on pages(or in Comments pane) and both such selections can coexist well. However, when you try to selected some comments and then try to select some content items on pages (or via Content pane) - then comments-selection will be immediately replaced by new content-selection. Because: content- and comment- selection are in the same virtual cluster of selections (clusterID='pagesView') and cannot be both in the same time and cluster. While the bookmarks-selection belongs to own 'bookmarksView'-cluster and doesn't 'conflict' with any selection from 'pagesView'-cluster and stays alive while you select content/comment. So, selection-clusters is a simple mechanism that allows you to determine which types of selections conflict with each other and which do not and can coexist in document at the same time.
IPXV_Document::GetSelCluster(selClusterID) - it returns current selection for specified cluster. For example IPXV_Document::GetSelCluster(Str2ID('pagesView')) may return existing comment-selection OR content-selection, OR links-selection, OR formField-selection.

IUIX_Layout::ClusterID - there is the similar idea but for other purpose: user will be able to D&D panes between two different layout-objects only when both of them have the same ClusterID. Currently we have only one case where many layout-objects have the same clusterID -- 'documentViewsArea' layout-objects which all have the same clusterID (it also equals to Str2ID('documentViewsArea')). As result - user can D&D document-tabs between different mainFrames but he still cannot put document-tab inside other document-tab for example (because inside document-tab exists layout-object with another clusterID='documentView').

HTH.

Re: IPXV_DocSelChangedEvent / IPXV_DocSelection / Cluster  SOLVED

Posted: Tue May 18, 2021 8:41 pm
by zarkogajic
Great. Thanks Vasyl for the detailed answer.


IPXV_DocSelChangedEvent / IPXV_DocSelection / Cluster

Posted: Wed May 19, 2021 5:55 am
by Sasha - Tracker Dev Team
:)