How can I change a text that appears whe you hover over edge in Roasal? I have not found this anywhere on the web
Change edge name that appears in popup on hover
148 Views Asked by Uko At
2
There are 2 best solutions below
0
On
A complete example of it could be:
view := ROView new.
el1 := ROBox green element extent: 50 @ 50.
el2 := ROBox blue element extent: 50 @ 50.
el1 @ RODraggable.
el2 @ RODraggable.
el2 translateTo: 50 @ 50.
aROEdge := ROEdge lineFrom: el1 to: el2.
(aROEdge getShape: ROLine) width: 5.
popup := ROPopup text: 'some text'.
popup textColor: Color black.
popup box color: (Color r: 0.9 g: 0.9 b: 0.9); borderWidth: 1; borderColor: (Color r: 0.8 g: 0.8 b: 0.8).
aROEdge @ popup.
view addAll: { el1 . el2 . aROEdge }.
view open
You can add a popup (with custom styling) to a single edge in the following way: