Page 1 of 1

Snap to grid?

Posted: Wed Sep 21, 2011 1:46 am
by keithglong
Hi All,

"Grid" is selected in my View menu, but I am not seeing any grid lines (nor are my objects snapping into place). Am I missing something. I am running LiveCode 4.6.4 on a Windows 7 machine.

Thanks!

- Boo

Re: Snap to grid?

Posted: Wed Sep 21, 2011 2:20 am
by WaltBrown
Boo,
I tried it. By default the grid snap to distance on my Win7 machine was 2 pixels, so it wasn't apparent. I went into menu->edit->preferences->appearance and changed it to 10 and the grid snapping became much more apparent.
Walt

Re: Snap to grid?

Posted: Wed Sep 21, 2011 3:22 am
by keithglong
Hi Walt,

Thanks for your reply. I actually tried that, but still no snap-to-grid action. Very odd.

Sincerely,

- Boo

Re: Snap to grid?

Posted: Wed Sep 21, 2011 3:28 am
by WaltBrown
That is. I can't replicate it. If you find out what is causing it....
Walt

Re: Snap to grid?

Posted: Wed Sep 21, 2011 3:44 am
by keithglong
Okay. I now see that when slowly moving an object (such as a button) around with Grid enabled, it does in fact move in increments according to my settings. I suppose I was under the impression that there would be some grid lines available, etc. (I have seen it this way in other development packages.) You know, where the objects snap to visible grid lines...

Thanks again,

- Boo

Re: Snap to grid?

Posted: Wed Jan 08, 2014 10:10 am
by Einherjar
Is there a way of showing the grid when using the snap to grid option?

Re: Snap to grid?

Posted: Wed Jan 08, 2014 12:11 pm
by Klaus
Einherjar wrote:Is there a way of showing the grid when using the snap to grid option?
No.

Re: Snap to grid?

Posted: Wed Jan 08, 2014 2:52 pm
by bn
Hi Einherjar,

I attach a little stack with a group in it. If you copy that group to a card it will show the current grid as a backgroundPattern of that card.
You can remove the grid from a button in that group. If you are done just delete the group from your card.
If you change grid spacing just remove the old grid and the button lets you draw a grid with the new spacing.

It is a little awkward but works, and it is not intrusive.

Kind regards
Bernd

Re: Snap to grid?

Posted: Thu Jan 09, 2014 2:56 am
by Simon
Hi Bernd,

Are you the creator of WheeLib?

Simon

Re: Snap to grid?

Posted: Thu Jan 09, 2014 8:07 am
by bn
Hi Simon,
Are you the creator of WheeLib?
no.
But is uses a widget (the wheel) I made.

it is what we discussed here:
http://forums.runrev.com/phpBB2/viewtop ... f=5&t=5870

and which evolved to an iOS7 style wheel/slotmachine

http://runtime-revolution.278305.n4.nab ... 73460.html

Kind regards
Bernd

Re: Snap to grid?

Posted: Thu Jan 09, 2014 8:18 am
by Simon
Thought it looked familiar. :D

Simon

Re: Snap to grid?

Posted: Wed Jan 15, 2014 10:29 pm
by bn
Hi All,

As a result of this thread I uploaded GridDrawer to revOnline. It is a much improved version or above's stack.

It lets you drag a widget on a card and lets you see a grid. The grid is a background pattern of the card where the widget is placed. Control grid size from the widget, toggles snap-to-grid from the widget.

I uploaded the widget to User Samples, (accessible from within Livecode) or
LivecodeShare, accessible via the net:

http://livecodeshare.runrev.com/stack/757/gridDrawer
gridDrawer.png
gridDrawer.png (11.84 KiB) Viewed 10546 times
Kind regards
Bernd

Re: Snap to grid?

Posted: Wed Jan 15, 2014 10:40 pm
by Kangaroo SW
Hello Bernd

Thanks for this fantastic tool !

Cheers
Rolf

Re: Snap to grid?

Posted: Wed Jan 15, 2014 10:45 pm
by bn
Hi Rolf,

Thank you, good to "read" you.

Any suggestions or bugs here or directly.

I like the inner working of the stack, which can be used to distribute widgets. It is an adaption from the Livecode Tools stack.

Kind regards
Bernd

Re: Snap to grid?

Posted: Thu Jan 16, 2014 3:10 pm
by bn
Hi All,

thanks to Rolf's tips Interface of gridDrawer widget now cleaner and you can move widget around the stack in browser mode by click-move.

http://livecodeshare.runrev.com/stack/757/GridDrawer

Kind regards
Bernd