Results 1 to 9 of 9

Thread: Severe OCD question - how do you move nodes in tiny increments

  1. #1

    Default Severe OCD question - how do you move nodes in tiny increments

    Sorry, this is an almost irrelevant question but my OCD really, really hates crooked lines in the graph.

    Basically, sometimes when you move a node you can't get it to line up with other nodes and it creates a crooked connection line - screenshot below. No matter where I move it, right click and align Left, Center etc it doesn't work. This goes further when nodes are grouped as the Output node doesn't seem to be able to be aligned.

    Is there an option like in Powerpoint where you can move a node in tiny increments to correct this ?

    ls.jpg

  2. #2
    Lavastorm Employee
    Join Date
    Apr 2014
    Location
    London
    Posts
    57

    Default

    Hey many of us Lavastormers share your love of an organised canvas! The three alignment options you have are either using the Arrange option from the right-click context menu, using the mouse or the arrow keys on the keyboard.

    I've never been unable to make all my lines straight but I'm assuming that you've already tried the options above? The first example looks like the bend point could be moved down but the second example should easily generate a flat line.

    Let me know if you need any further help.

  3. #3
    Lavastorm Employee stonysmith's Avatar
    Join Date
    Nov 2006
    Location
    Grapevine Tx
    Posts
    799

    Default

    Click the elbow once and a black circle will appear. From there, you can either drag with the mouse, or you can use the cursor up/down keys to move it around on the screen.

    As to the output pin being "out of place".. I have seen that from time to time, but it's pretty rare. It often straightens up when you close the graph and re-open it. I suppose if you REALLY wanted to fix it, you could edit the BRG as a text file, and look for line(s) such as this:
    editor:XY=130,190

  4. #4
    Lavastorm Employee
    Join Date
    Dec 2006
    Location
    Dallas, TX
    Posts
    297

    Default

    I have that same affliction. And I tend to think that well formatted graphs are more likely to work correctly. And it might only be because someone has taken the time to review it enough to make it look reasonably good.

    I expect/hope andycooper's answer might help, but with the additional step of temporarily putting ALL of the nodes in the same horizontal line. Then moving it back to it's current location.

    I'm not afflicted enough to try stonysmith's solution yet, but as a last resort I'm 100% sure it works. (disclaimer: you can potentially mess up other things when doing it and don't blame me if it goes bad)

    BTW: I haven't been able to fix this on inFlow nodes where I've changed the size yet. But I admit to not having tried andycooper's solution on it yet either. What I've done there is cheat by adding an elbow and hiding it behind the inFlow node.

  5. #5
    Contributor
    Join Date
    Feb 2009
    Location
    Chicago
    Posts
    194

    Default

    I've rejected peoples code for promotion into production for lines not looking neat and tidy. There is no OCD about it. Makes things easier to read

  6. #6

    Default

    77 Views and 4 great replies make me feel a bit better about posting over a crooked line :-).

    I've tried aligning, distributing, aligning everything into a ball, every variation of aligning, creating elbow joins - none of it worked (including turning the computer off and on again :-) ) . It's like a node just gets one pixel out and can't be fixed.

    The solution was the suggestion from StonySmith - edit the code in Notepad and change the X/Y references for all nodes in the group. It's really simple, just do a find for the node name then look for the line that says "editor:XY=". Eg - mine said "editor:XY=590,140".

    What I found is that wonky nodes had odd numbers eg 590,139, so moving them in the graph was moving them to another odd number. Changing them to even numbers eg. 590,140 put them in a straight line and I could then move them into formation in the graph as normal.

    For the Composite Output node the XY reference is in the Composite Node text itself as "outputxy:0=650,140" - there isn't a separate code for the Output node

    Thanks everyone :-)
    Last edited by dglavastorm; 09-01-2014 at 01:34 AM.

  7. #7

    Default

    Two quick points for anyone trying this -

    You can change the source code while the graph is open in LS. When you save in Notepad, LS will advise the code has changed and needs to reload. This means you can see your changes live as opposed to shutting down/reopening the graph every time.

    Make a backup ! Editing the source code of course means there is no Undo if something goes wrong. Really, really obvious point but one that I didn't think ahead for. Fortunately nothing went wrong :-)

  8. #8
    Lavastorm Employee
    Join Date
    Aug 2009
    Location
    Cologne
    Posts
    513

    Default

    Hey,

    Just got around to looking at this now.
    It is generally not advised to go and change around your BRG manually as the format is ... somewhat odd and picky and can lead to serious problems, however it looks like you've figured out the pieces you need to change and got the problem sorted.

    It would be better obviously to be able to handle this correctly within BRE and not require this manual source hacking.
    I just tested this a little (hacked a BRG to change the Y position of a node, then tried changing the alignment of that node selected with another in BRE) and from what I can see, using the alignment options will work for lining up all the nodes.

    However, this doesn't work for the composite input/output pins as these are never aligned by BRE.
    Further, bendpoints are not aligned.

    I don't think in general that the bendpoints *should* be modified via the align operations, but ... maybe that could be an additional enhancement.
    The composition input/output pins certainly should be.

    Can you confirm whether or not you were able to line up the nodes themselves, but just not the composite input/output pins - or were you unable to align the nodes as well?


    There are issues on nodes with different sizes (such as inFlow nodes containing images which have been resized) which are still outstanding issues to fix.
    Essentially, the alignment operations work on the X/Y positions of the nodes, which are actually the centre of the nodes.
    This doesn't take into account the fact that resized nodes will have different sizes and simply using the centre position will not work for aligning left, top, right, bottom, etc.


    Regards,
    Tim.

  9. #9

    Default

    Hi Tim, sorry I haven't checked back on this thread for a while. It was normal nodes as well as input/outputs and elbow joints. These can be the same nodes as well - eg. 2 filters can be slightly out.

    It happens every so often, a node just isn't on the same alignment as the others. Selecting Align Middle and so on didn't help - when you then move them back out the same issue occurs. As I described above, it's because some nodes have odd numbers in their XY co-ordinates and others are even. Moving them moves them in 2 point increments so they are always odd or even.

    I haven't had any issues text editing the BRGs and it's actually taught me a lot about how nodes work, but like you say it's not a good solution as editing anything else could cause issues - something probably more an issue for us "poke it to see what happens" types :-). Hence my note to people about creating a manual backup first.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •