Is there a way to allow the user to select the entire editor when they click on an individual cell?

Hi,

The editor for my smart reference concept includes a referent node along with some constant nodes and a model access node. The are enclosed in a horizontal collection. Is there a way when the user clicks on any of these sub cells that all the cells of the editor are selected?

Currently only the cell the is clicked on is highlighted by MPS. The user has to use Cntrl+Left+Arrow keys to select the entire editor so the they can press Cntrl+Space to bring up the substitution menu.

Ideally I want to allow the user to select the entire editor without having to use the Cntrl+Left-Arrow key combination so it's more intuitive. The constant cells, etc are decoration basically and are not meant to be handled separately.

I know I can add a context assistant with a transform menu to bring up the substitute menu.

 

0
5 comments

I don't know about what you're asking, but you can also specify a transform or cell menu for any cell, so you can make Ctrl+Space work on any child cell without having to select the entire node first.

0

I'm asking is there anyway I can treat multiple cells like a single cell in terms of Ctrl+Space.

0

Yes, I meant I didn't know how to do what you're asking (changing selection). Would assigning a menu to each of these cells help in your case?

0

OK I see.That would solve one issue.

I was having a problem where if the user clicks on the referent cell and brings up the substitution dialog it seems to ignore the scope provider on the parent node/concept and just lists all possible references for that smart reference. That doesn't happen if I select the entire node (all child cells) and hit cntrl+space.

I'm going to have another look at my code and get back to you as I think I overlooked something when reviewing/testing my concept.

 

0

I didn't implement the second scope provider method (the two argument one) so that's why I wasn't seeing what I expected.

I was able to get very close to the behaviour I wanted by:

1. Setting the style of all cells except the first and last to readonly = true and selectable = false. 

2. Setting the style of the horizontal collection cell to show-boundaries-in : gutter-and-editor.

3. For the first and last child cell I added the transformation menu: "default menu for <smart reference concept>".

When the user clicks on the  node the first and last cell is highlighted (via show-boundaries-in) and the mouse carrot goes to either the first or last cell depending on where they clicked in the node. Then they can hit cntrl+space to bring up the substitution menu.

I tried adding a transformation menu to all child cells but it didn't look great.  The above is the closest to giving the appearance of the entire group of cells being one selectable entity.

Thanks for your help.

0

Please sign in to leave a comment.