We are working on an application in which when we give “create diagram” it opens a canvas page with node palette at the left side. We need a label which should come at top center on load of the canvas page.
For that we tried hard coding position(loc : “0 0”) to the label in node data array. For whatever positions we give to the label it is visibly coming at the middle of the canvas page only.
We tried using intialContentAlignment, it works for label but when we drag and drop other nodes that will take that intialContentAlignment value and push the label downwards .
PFB code where we are hardcoding label position:
desc:“Click here to add title”,
font:“normal 20pt Segoe UI, Arial, sans-serif”,
label:“Click here to add title”,