[Plugin] 2D Tools
-
@Matte
There should be a subfolder of additional PATs too...
You just need to make a jpg image.
It needs to 'tile' - that is the images need to repeat when placed next to each other in X & Y.
Use an existing PAT file for clues on size and 'tiling'... lines on the right side need to match up with lines on the left side, and lines on the top side need to marry up with lines on the bottom side...
If you make some new ones, then please consider sharing them with everyone else... -
@topaz505 said:
Tig, I have been trying, off and on, for several months to get the hang of applying Styles to Lines. I just don't get it !
1st question: can you apply 2D Line Styles to native SU lines ?
2nd question: I assume that if you set a 2D Line Style that the next (and subsequent) 2D Lines that you draw will be in this style ?
3rd question: can you give the keystrokes to apply a new 2D Line Style to an existing line ?- ancilliary question: can you keep on changing the Style of a line ? (My experience suggests that you can only do this once - but that's probably me.)
A request: would it be possible to create a version with fewer colours and widths ?
My application is more engineering drawing than "art" drawing or architecture. I really need a few bold colours, continuous, dashed and dotted lines and a few thicknesses, (the colour menu especially is just bewildering).
PS I have read the Help file and watched the Video - many times, but the plug-in's charms are avoiding me as yet, but I hope to get there.
Thanks in advance.
You pick/select any Sketchup 'Line' and 'Style' it - it replaces the Line with a colored face group, which is then editable later as it's recognized as a Styled-Line - the original line is kept and moved onto a hidden Layer - it can't be erased as it might be needed by a face.
You assumption is wrong... all 2d-lines are just lines/edges like in SketchUp's native tools. You apply a Style to line AFTER they are created, once Styled they are editable [context-menu]...
If you want to make a shortcut key that's straightforward... Use the Preferences shortcut key and navigate to the 2dtools submenu item...
There are some tricks to using a long list...
If you want to customize the color list then you must edit the code...
I think this was already discussed for the 2dtext tool etc...
http://sketchucation.com/forums/viewtopic.php?p=263662#p263662
To make your own list of colors etc do something like this: use Notepad.exe to edit the file ../Plugins/2DTools/2DlinestyleTool.rb
Assuming you are 'metric'... find the line #158 reading:
widths=["1|2|4|5|8|10|20|25|30|40|50|60|70|75|80|90|100|125|150|175|200|250|300|400|450|500|600|700|750|800|900|1000|1200|1500|1800|2100|2400|2700|3000|3300|3600"]
These are in 'mm', remove the ones you don't want within the " ". It must start and end with a number and each in the list is separated by a '|' symbol.
So for a limited range of 1mm to 100mm you would use something like:
widths=["1|2|5|10|25|50|75|100"]
If you are expecting to work in 'inches' change line #156 instead.
For the colors, find lines #163..#165.
colors=[]; materials.each{|m|colors.push(m.display_name)} colors=colors+(Sketchup::Color.names.sort!) colors.uniq!; colors=colors.join("|")
IF you just want a few colors you can leave the code above unchanged, BUT then add a line immediately afterwards saying this:
colors=["Black|White|Red|Orange|Yellow|Green|Blue|Violet|Brown|Gray"]
that will redefine the 'colors-list' just to those few [always include at least 'Black' to avoid it tripping up]... -
TIG,
just for your information, I get repeated crashes whenever I tried to undo a 2D fillet.
regards.
-
@edson said:
TIG,
just for your information, I get repeated crashes whenever I tried to undo a 2D fillet.
regards.
I recall something like this before...http://sketchucation.com/forums/viewtopic.php?p=431842#p431842 I get no such issues, with Undo working exactly as you might expect... and the many hundreds of other users also have no issues...
This suggests that you have installed a script that is adversely interacting with my 'innocent' tool...
Have you [recently] installed/activated something that is on the SCF Quarantine list, or perhaps one of the new BIM tools that add clumsy observers or mess with native class/methods, or several Render tools loading all at once which can interact badly, or some new fangled tool that I might not have [yet] ?? -
I have none of the quarantined plugins installed and the only rendering plugin I have is podium. I am not sure if BuildEdge Plan qualifies as a BIM extension.
-
I think BuildEdge has been causing some issues...
-
@edson said:
I have none of the quarantined plugins installed and the only rendering plugin I have is podium. I am not sure if BuildEdge Plan qualifies as a BIM extension.
It does. Indeed the link I provided was about the update of the 2dFillet tool to sidestep the BuildEdge Plan toolset messing with innocent native processes - because they wouldn't respond to fixing their mess I decided to rewrite my tool which now avoids their created issues !So have you downloaded the very latest version of 2dTools [off the first post in this thread] - it contains the updated 2dFillet tool that will live in harmony with BuildEdge Plan [although I can't promise that BuildEdge Plan won't break something else!]
-
@tig said:
@edson said:
I have none of the quarantined plugins installed and the only rendering plugin I have is podium. I am not sure if BuildEdge Plan qualifies as a BIM extension.
It does. Indeed the link I provided was about the update of the 2dFillet tool to sidestep the BuildEdge Plan toolset messing with innocent native processes - because they wouldn't respond to fixing their mess I decided to rewrite my tool which now avoids their created issues !So have you downloaded the very latest version of 2dTools [off the first post in this thread] - it contains the updated 2dFillet tool that will live in harmony with BuildEdge Plan [although I can't promise that BuildEdge Plan won't break something else!]
thanks for explanation. however, I am almost sure I had the latest version of 2D Tools installed. just to be sure I downloaded and installed it. let's see how it goes now.
-
Tig, I have been trying, off and on, for several months to get the hang of applying Styles to Lines. I just don't get it !
1st question: can you apply 2D Line Styles to native SU lines ?
2nd question: I assume that if you set a 2D Line Style that the next (and subsequent) 2D Lines that you draw will be in this style ?
3rd question: can you give the keystrokes to apply a new 2D Line Style to an existing line ?- ancilliary question: can you keep on changing the Style of a line ? (My experience suggests that you can only do this once - but that's probably me.)
A request: would it be possible to create a version with fewer colours and widths ?
My application is more engineering drawing than "art" drawing or architecture. I really need a few bold colours, continuous, dashed and dotted lines and a few thicknesses, (the colour menu especially is just bewildering).
PS I have read the Help file and watched the Video - many times, but the plug-in's charms are avoiding me as yet, but I hope to get there.
Thanks in advance.Edit: Tig, Many thanks for your complete and helpful reply. Rob
PS Northumberia is great; I was there for 3 years in early '70's ! -
TIG:Hello
I use Chinese text annotation does not work! Other languages working properly. -
I have PMd you a lingvo encoded as UTF8 without BOM rather than ANSI.
Report if that works better ? -
First the good news:
- I applaud the intent and effort of this plugin...something like this is badly needed
- I appreciate how complex this must be to do
Now the bad news:
- This plugin has a way to go to being useful
- line selection is intermittent at best (may take up to 10 tries to pick the lines
(and that is even in an open area looking down from the top...no shapes near by) - For Line style...Not sure the merit of creating 1000s of faces along a path.
Wouldnt it be easier to take the selected lines, copy them, and offset them from
original, and tie end points together. At least that way you dont get all the
aliasing on curves? If you are really into 1000s of faces, then trapazoids
or triangles would be better. - Color selection really doesnt work....I end up ungrouping to lowest level and pick
color from palate or whatever then regroup them. (other than black, the selected
lines disappear. - Since this tool doesnt line stretch like the native line tool, wouldnt make sense
to keep/hide original line and offer the option to return to it for movement and
such....maybe use the original line a guide the user can adjust, the resulting
line follows the adjustment. For example, assume you make a sort of "S" line.
With the default tools, you can move the center horizontal and left/right
verticals tag along. Your tool breaks that connection so that user has to
stretch /shrink (is that the idea of the "adjust" tool??)
- line selection is intermittent at best (may take up to 10 tries to pick the lines
Again...I applaud the efforts so far
-
vojo, I'm looking forward to your new version of the plugin that handles these things as you describe. Any hint as to when you'll be releasing it?
-
Thank you for your comments.
If you want to make an alternative toolset from scratch please do so.
These tools have been around for some years and there are thousands of happy users, so I have no intention of making an major changes myself.The selection of a '2d' line should be no different from native lines.
Perhaps it is you?
Perhaps you have a graphics-card or mouse issue.
A '2d' line is the same as a native line except its Z-height is fixed.
Connected sets of 2d lines do not auto-face - unlike the native line tool - this is intentional because it lets you draw lines without unwanted faces popping into existence.
There have been many attempts over the years to 'style' lines.
To allow 'patterns', thickness and color in one tool cannot rely on using stacked lines.
Using faces makes far less geometry than dozens of stacked lines per dot - also how are you going to 'color' these lines.
Once a line is selected and styled the styled proxy is no longer connected to the source line that is now on a hidden layer. You wouldn't normally style lines until the layout of lines is set, however if you do need to it's easy enough to unhide the original lines' layer and select+delete the styled version, then restyle it as desired.
The complexity of 'linking' the original line to its styled proxy would require adding matching attributes and having observers watching the pairs of styled geometry, and auto-adjusting that geometry as one of them changed. This extra layer of complexity seems far in excess of its usefulness.
No one makes you used styled-lines.
Either accept them as they are or if you have devised a better solution that works then please let us all know.
The 'adjust' tool is intended to do multiple extend/trim actions on sets of lines/curves.Have you read the 2d toolset's instructions?
If you want complex line making, styling etc then use "Layout"- the 2dTools set was devised to do a few specific actions some time ago - if you want other tools devise them...
-
too new sketchup to step up yet and make a plugin...no offense intended
RE Selection....np problems with pencil or several other plugins in selected what is desired Fredos stuff works fine
RE read the instructions several times....they need to be more of a cookbook not a blog
RE aliasing on curves...I dont think its the graphics engine....I zoom in enough and can see the gaps form as the rectangle progression bends...if graphics, would have thought as I zoom, the same polka dot pattern would persist....not have cleaner and cleaner breaks as I zoom in.
In thinking about this, the I believe the better way to go is the following
For each segment in selection
place a perpendicular segment at start point and end point
segment length adjusted based on thickness (can default to some value to start)
note the ends of each segment in 2 arrays
left_array has each T segment start point
right_array has T segment end point
end
connect all the left array points with segments
connect all the right array points with segments
May need to remove T segments...but maybe hide is good enough...dont know
connect left array first point to right array first point
connect left array last point to right array last point
ensure closed
apply a colorThis will get around the aliasing issue on curves ( at least reasonable curves)
The left segments and right segments, if I understand sketchup, should be preseved
(changing line width later would be to extend the T segments - if hidden, or recreate if deleted via original or scaling using Pythagoras - along their slopeRE faces....I dont know about that (novice)....maybe set up as a group until completed, then explode. At least a group wont get "distracted" by neighboring shapes.
Dont get me wrong....I applaud what you have done and are trying to do....honestly, just trying to be helpful
some background:
What I am trying to do is what make line connectors between shapes to illustrate a network diagram. Think a "4" without the upper right segment. I want to make the corners rounded
Now to be far, I completely realize sketchup is not visio, but in visio, this can be highly automated without any VBA or code. Instead, control handles can be defined for user to move things as needed. Unfortunately, after struggling with 2Dtools for a week, I decided to make my own connectors and edit / adjust the standard sketchup way. -
Use LayOut.
-
To be frank, if I wanted a rich 2D presentation tool for a couple of hundred bucks, I would get visio. All other pluses/minus aside, at least there one can automate the drawing details without scrips, plugins, VBA/Ruby, etc
(autosize text on a shape, change colors based on parameters of shape, etc)
Sketchup is great at 3D "sketching" just not focused on productivity tasks and that is
perfectly fine. However, the key issue I believe is missing is a way to draw thick lines that are usable. I applaud the efforts, but a tessellation of rectangles doesnt work in the generic case. -
Layout can do that stuff. But I guess you'd rather have it given to you for free and still complain.
-
you are right....I keep forgetting the mantra for open source....free but doesnt quite work
-
The toolset works just fine - doing what it designed to do.
BUT it doesn't work how YOU think it should.
That is quite different!Many things in my life don't do everything I'd like them to, but it doesn't mean they don't work...
I either accept what they do, or find/amke an alternative...If you are so keen on having a tool that does some action specific to your perceived needs then feel free to invent it.
No one is making you use any tool at all.
You choose what you want from what is available.
If it's not available then make it.As Dave said... if you want more than to be able to make the occasional 2d object then use Layout - that is designed specifically for 2d work - after all SketchUp is a 3d modeling tool, and 2dtools add a few 2d-like tools that can be useful now and again BUT it's not trying to make SketchUp into a 2d-tool...
Advertisement