LabVIEW Idea Exchange

cancel
Showing results for 
Search instead for 
Did you mean: 
Ray.R

Keep alignment when moving multiple objects

Status: New

When selecting objects on the Front Panel and using the Shift + Up or Down arrow key, it moves them to the nearest grid line and successive shift+arrow keys keep things on the grid.  This is fine when selecting a single object, However, when selecting multiple objects that are not perfectly aligned, it may result in a misalignment.

 

The idea being suggested is when multiple objects are selected they should retain the original alignment between objects.  A more sophisticated version could allow the user to select in the options whether objects that are aligned within a given small number of pixels should automatically be perfectly aligned and moved together.  The idea is to prevent having to re-align an object after using the Shift + Arrow to move them.

 

See image below:

 

6 Comments
Ray.R
Knight of NI

Alignment options could be : 

1) preserve:  move both objects while preserving the alignment

2) align:  first align the objects and then move them together

 

The options would be set in the usual spot under Front Panel options.

 

_Y_
Active Participant
Active Participant

It is always good to avoid "smart behaviour". However, wouldn't simple groupping solve the problem in this case?

_____________________________________
www.azinterface.net - Interface-based multiple inheritance for LabVIEW OOP
Ray.R
Knight of NI

I usually align the objects on the Front Panel.  For some reason, it was out of alignment by 1 pixel when I saw a behavior that was not quite right to me.

 

I also group objects which are meant to stay together (no change in distance between the objects).  In this particular cae, I did not want to group the error clusters because although I like to align them horizontally, I may not wish to keep their vertical distance constant.  As a matter of fact, as the VI grows, their distance may change; hence, I do not group them.

 

I am not sure what you are referring to as "smart behavior", since the the behavior I am looking for is quite simply to move the selected objects the same distance (in this case vertically) when I use the up / down arrows.  That way they retain their original alignment.  There is no complex decision making in the process.

Darin.K
Trusted Enthusiast

The group command is in no-man's land with no keyboard shortcut and option to add it.

 

Current implementation of shift-arrow:

 

if(alignment)

  snap = 0

  foreach (object)

    if (object !aligned)

      snap++

      snap object

  if (snap = 0)

    foreach (object)

      move 1 grid

else

  foreach (object)

    move 10 px

 

Proposed implementation:

 

foreach (object)

  move 1 grid  //get rid of arbitrary 10px value, respect the grid whether or not you are aligning to it.

 

The new implementation is easy to learn (and remember!), maintains grid alignment, maintains relative alignment, and is consistent with the behavior of other modern graphical tools.

 

 

JB
Trusted Enthusiast
Trusted Enthusiast

Having been annoyed countless times by this behavior, I can only kudo your idea !

hecmar.arreola
Active Participant

The NI Dashboard app for iPad control alignment functionality is currently superior to LabVIEW's 😞 😞 😞