anxb26 / fritzing

Automatically exported from code.google.com/p/fritzing
1 stars 1 forks source link

Snap to grid #370

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
If a part (or multiple parts) are selected, the arrow keys (up, down, left, 
right) should move the part 
over the canvas. The step of movement should be the grid size (*)

* the grid size for breadboard is simple: 0.1"
The grid size for schematic could be the same (or 10 pixels or some)
The grid size for the breadboard should probably be a bit more fine, because 
elements needs to be 
more precisely placed, grid is 1 mm?

Original issue reported on code.google.com by dirk.van...@gmail.com on 12 Dec 2008 at 3:18

GoogleCodeExporter commented 9 years ago
In general, we might want to have a togglable grid, at least for schematic and 
PCB 
view. People are used to this from other tools and it helps to make everything 
look 
nicer.
Both mouse dragging and arrow key tapping should adhere to it then.

Forum post http://fritzing.org/forum/thread/44/

Original comment by andre.knoerig@gmail.com on 18 May 2009 at 1:40

GoogleCodeExporter commented 9 years ago
Issue 76 has been merged into this issue.

Original comment by irasc...@gmail.com on 19 May 2009 at 2:27

GoogleCodeExporter commented 9 years ago
r3985: added an experimental align-to-grid feature.  Toggle it on/off from the 
view menu (available in debug mode only).  Currently, it 
only applies to dragging parts within a sketch.  Grid size for both PCB and 
breadboard view is 0.1 inches; Schematic view is 0.3 inches 
(this was a wild guess based on looking at a random part).  Grid size is easy 
to change.  

I guess the idea is to try it out and see what we think.

The following features/cases are not yet integrated/dealt with (and maybe some 
of them don't need to be...)

rotation
dragging wires
autoscroll during dragging
swapping parts
moving items via arrow keys
if the dragged object has no connectors
alignment offset from board (pcb view) rather than from (0,0)?
when dragging parts from the parts bin
parts that don't align (probably the most will be in schematic view) 
visible grid lines (I'd have to be convinced...)
autorouting

What else is missing?  What can we skip in the list above?

Original comment by irasc...@gmail.com on 12 Feb 2010 at 10:39

GoogleCodeExporter commented 9 years ago
enforcement in the parts editor?

Original comment by irasc...@gmail.com on 12 Feb 2010 at 11:04

GoogleCodeExporter commented 9 years ago
arrow keys, dragging boards, and drag from parts bin (except for breadboards) 
are now 
working.  Boards are aligned to the grid from their top left corner, so the 
grid stays 
with origin at (0, 0).  

A new sub-issue is if you drop a part in one view, if any of the other views 
are align-
to-grid, the part won't be aligned in those views.

Original comment by irasc...@gmail.com on 13 Feb 2010 at 7:06

GoogleCodeExporter commented 9 years ago
Wow, this works surprisingly well! So far it's just a few parts that are not 
properly 
designed. But we need to fix them anyway. Good job!

Original comment by andre.knoerig@gmail.com on 13 Feb 2010 at 10:39

GoogleCodeExporter commented 9 years ago
cross sub view is working, dragging breadboards from partsbin is working

Original comment by irasc...@gmail.com on 14 Feb 2010 at 5:07

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
Wire bendpoints also need to snap, in order to make nice straight lines. 

However, the _end_points might need to be flexible, in case that some connector 
is off. 
As far as I can tell, this is only a problem in PCB view (maybe eventually also 
in 
breadboard view), where the physical reality doesn't always adhere to a grid. 
Look at 
the XBee part for example.

Original comment by andre.knoerig@gmail.com on 16 Feb 2010 at 9:02

GoogleCodeExporter commented 9 years ago
I went through all the parts to see how they are doing and compiled a list here 
(on the 
second sheet): https://spreadsheets.google.com/ccc?
key=0AvNqaYKv9Rs6dG5PZGJ2TVh3UURkR3I1RWtRZTZWUnc&hl=en 

Looks like 99% of the breadboard are working, but only 5% of the schematics..

Original comment by andre.knoerig@gmail.com on 16 Feb 2010 at 9:38

GoogleCodeExporter commented 9 years ago
wondering if "align to grid" should be the default

Original comment by irasc...@gmail.com on 18 Feb 2010 at 8:37

GoogleCodeExporter commented 9 years ago
r3996: wire bendpoint snap-to-grid.  May be a little flaky, but hard to pin 
down.

Original comment by irasc...@gmail.com on 18 Feb 2010 at 9:21

GoogleCodeExporter commented 9 years ago
should alignment to grid be saved as part of the sketch? or is it a property of 
fritzing, so its state should saved when you quit fritzing and restored when 
you 
restart fritzing?  or both?

Original comment by irasc...@gmail.com on 19 Feb 2010 at 3:30

GoogleCodeExporter commented 9 years ago
It should only be saved with Fritzing, not with the sketch.
In PCB view and schematics view it will also be useful to be able to set the 
grid 
size manually.

I think it's good enough that we can put it into the release, but turned off by 
default. And then ask for feedback.

We have some very nice graphics from Dirk for the grid in th background. These 
are 
very useful visual guides, but might difficult to make them performant.

Original comment by andre.knoerig@gmail.com on 19 Feb 2010 at 5:48

GoogleCodeExporter commented 9 years ago
If you can set the grid manually in the other views, might as well in bb view.  
How do 
people access that setting and what widget do they use.  I suggest that it's 
either 
part of the preferences dialog, or there's a separate alignment settings menu 
item next 
to the align to grid menu item which brings up a little modal dialog window.  
The 
widget could be another version of the zoom slider, though that seems like 
overkill. 

Original comment by irasc...@gmail.com on 19 Feb 2010 at 8:29

GoogleCodeExporter commented 9 years ago
I'ld put the grid setting dialog in the Preferences. And a simple toggle on/off 
in the menu, coupled to a key-
shortcut e.g. Ctrl+Shift+' (like people are used to from photoshop)

Original comment by dirk.van...@gmail.com on 20 Feb 2010 at 7:20

GoogleCodeExporter commented 9 years ago
r3999: separate dialog for choosing grid size; grid settings are saved, 
restored the 
next time you run fritzing.  Both Mariano and I looked into having an actual 
grid in 
the background but it's tricky and slows things down.  Closing this issue--open 
a new 
one if further work needs to be done.

Original comment by irasc...@gmail.com on 21 Feb 2010 at 10:56