Utility node new in 3.1

Align

Keeps an element where it belongs at any window shape — a preview in a corner, a panel along an edge, a picture filling a cell. Uncabled it works in the whole Render View; cable a Frame (a Layout cell, or another Align's Frame) to work inside that. Anchor picks the corner, edge or centre; Margin and Offset are proportional (% of the short side, or of the frame), so a 3 % margin looks the same on a phone and a wall. Size Mode: Fixed (a share of the frame, Lock Aspect keeps the proportions), Original, Fit, Fill (cover — cable Clip so nothing spills), Stretch, Fit Width, Fit Height. For a Canvas showing a whole picture, cable X → Position X, Y → Position Y, Scale X / Scale Y → Scale X / Scale Y, Clip → Clip. Show draws the frame, margins and anchor over the Render View.

Inputs

PortTypeDefault
EnableOff: the outputs give the whole frame unchanged.booltrue
FrameWhere to place the element: a Layout cell or another Align's Frame. Uncabled: the whole Render View, following every resize.structure—
AnchorWhich point of the frame the element holds on to: a corner, an edge's middle or the centre. Custom uses Anchor X / Y.int—
Anchor XCustom anchor across the frame, 0 = left edge, 1 = right edge.float1
Anchor YCustom anchor down the frame, 0 = top edge, 1 = bottom edge.float1
PivotWhich point of the ELEMENT sits on the anchor. Same as Anchor puts the element's corner in the frame's corner; Center centres it on the anchor.int0
Pivot XCustom pivot across the element, 0 = its left edge, 1 = its right edge.float0.5
Pivot YCustom pivot down the element, 0 = its top edge, 1 = its bottom edge.float0.5
UnitWhat Margin and Offset are a percentage of: the view's short side (the same distance on every side, at any shape) or the frame (width across, height down).int—
MarginSpace kept between the frame's edges and the element, all sides, in Unit percent.float3
Margin LeftExtra space on the left, added to Margin.float0
Margin RightExtra space on the right, added to Margin.float0
Margin TopExtra space at the top, added to Margin.float0
Margin BottomExtra space at the bottom, added to Margin.float0
Offset XMoves the element right (negative: left) after anchoring, in Unit percent.float0
Offset YMoves the element up (negative: down) after anchoring, in Unit percent.float0
Size ModeHow big: Fixed (Width / Height as % of the frame), Original (its own size), Fit (all of it inside), Fill (covers the frame — cable Clip), Stretch (exactly the frame), Fit Width, Fit Height.int—
WidthFixed: the element's width as % of the frame inside the margins. 0 = from Height and the proportions.float30
HeightFixed: the element's height as % of the frame. With Lock Aspect on it is ignored when Width is set.float0
Lock AspectFixed keeps the content's proportions: the other side follows from the one you set.booltrue
Content WidthThe element's own width in Grafit units — cable a generator's or Text as Image's Width. 0 = a whole Render View picture (a Canvas in Size Auto).float0
Content HeightThe element's own height in Grafit units — cable its Height. 0 = a whole Render View picture.float0
AspectOverrides the content's proportions, width ÷ height: 1 square, 1.778 for 16:9. 0 = from Content Width / Height.float0
ScaleA multiplier on the size after the mode.float1
Min SizeThe element's shorter side never goes below this % of the view's short side (proportions kept).float0
Max SizeThe element never grows past this % of the frame on either side (proportions kept). 100 = no limit.float100
EaseSeconds to glide to a new place when the frame, anchor or size changes. 0 = jump at once.float0
ShowDraws the frame (dashed), the margins (shaded, with their values), the anchor and the element over the Render View — guides only, never in the picture.boolfalse
ImageCable the picture the Canvas shows: its proportions are read from it every frame and replace Aspect, so a crop or a new file never stretches.image—
Crop AlphaPlaces only the visible part of the Image: the anchor, margins and size apply to what you see, not to its transparent surroundings. The picture is moved and clipped, never copied. Measured a frame late on the GPU.boolfalse
ThresholdCrop Alpha: how much alpha counts as visible (default 0.01). Raise it to ignore faint glow and crop tighter.float0.01
PaddingCrop Alpha: space kept round the visible part, % of the picture's short side — room for soft edges.float1
Grow OnlyCrop Alpha: the visible part only grows (a running union), so moving content is measured once and then stands still. Off: it follows every frame.booltrue

Outputs

PortType
Xfloat
Yfloat
WidthFixed: the element's width as % of the frame inside the margins. 0 = from Height and the proportions.float
HeightFixed: the element's height as % of the frame. With Lock Aspect on it is ignored when Width is set.float
ScaleA multiplier on the size after the mode.float
Scale Xfloat
Scale Yfloat
Leftfloat
Rightfloat
Topfloat
Bottomfloat
FrameWhere to place the element: a Layout cell or another Align's Frame. Uncabled: the whole Render View, following every resize.structure
Clipstructure

Open Align in the interactive catalog →

Align is one of 381 nodes in Grafit Pro.

Free download. Every feature for 7 days, no card. Then €99.99 once — or keep playing your projects as a Player.

More Utility nodes