News:

BB code in posts seems to be working again!
I haven't turned on every single tag, so please let me know if there are any that are used/needed but not activated.

Main Menu

Custom Linetype issues

Started by NathanVis, March 04, 2020, 07:47:35 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

NathanVis

This may be the most OCD thing I have ever sought.  I made custom linetypes to show communication wiring; depending if the line is writing right-to-left or left-to-right, sometimes the letters go upside-down. This is really nitpicky, but is there code that I could put into the arc I used to make the C so that it is always oriented "up" no matter which way the line is going?  I tried opening the shapesheet of the arc that is the C and setting LockRotate to 1, but that didn't change the linetype activity.

Paul Herber

In the shapesheet editor set section Text Transform cell TxtAngle = -ANG360(Angle)
Electronic and Electrical engineering, business and software stencils for Visio -

https://www.paulherber.co.uk/

NathanVis

The "C" in the linetype is not text-it is an arc because when I tried to do it with an actual text C it would not show up.  I put "=-ANG360(Angle)" into the Shape Transform section cell Angle, but I got the message saying it is "Circular formula reference"

wapperdude

Can you upload an example of your shape?  Sounds like something is blocking view of the letter "C".
Visio 2019 Pro

NathanVis


Visio Guy

Which versions of Visio are showing the "C" in a custom line pattern? I can't recall that every working, and it is certainly not working for me in Visio Plan 2.
For articles, tips and free content, see the Visio Guy Website at http://www.visguy.com
Get my Visio Book! Using Microsoft Visio 2010

Visio Guy

For me to see a C, I have to draw a graphical C, fonts don't show in custom line patterns for me.

Regardless, there is no way to have ShapeSheet logic operate on "pattern instances". The pattern is frozen at the time Visio applies it to the line.

I can't think of a solution to this, unless you create specific-purpose lines that have predetermined segments. Ie: you could build an S-shaped connector and control which ways the individual segments were drawn, based on the endpoints of the connector. Reversing the order of the points would change the way the pattern is applied. Kind of a pain, but possible.

If you need arbitrary paths, then there's no way to build a SmartShape that can do it without the assistance of some code.
For articles, tips and free content, see the Visio Guy Website at http://www.visguy.com
Get my Visio Book! Using Microsoft Visio 2010

vojo

One possibility:

Create a connector or line group
- place a text box for some message ...say "CCC"
- Give a control handle so you can move it around
- the end points can be moved around for the path you want
- the control handle can place the text where you want it
    - use gravity for orientation perhaps

sort of like attached...needs polish....use controls on left

vojo

could even look at a text transform in the connector shape and use controls to move in that domain
(vs the kludgy pinx / piny I did in 10 min).

First on could be in line (set text background to white)...polish as needed
Second one might have problems with in line since you will need figure out white background on text.

Browser ID: smf (possibly_robot)
Templates: 4: index (default), Display (default), GenericControls (default), GenericControls (default).
Sub templates: 6: init, html_above, body_above, main, body_below, html_below.
Language files: 4: index+Modifications.english (default), Post.english (default), Editor.english (default), Drafts.english (default).
Style sheets: 4: index.css, attachments.css, jquery.sceditor.css, responsive.css.
Hooks called: 296 (show)
Files included: 34 - 1306KB. (show)
Memory used: 1162KB.
Tokens: post-login.
Cache hits: 13: 0.00182s for 26,739 bytes (show)
Cache misses: 3: (show)
Queries used: 17.

[Show Queries]