Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
metapost [2019/11/30 23:14]
tarquinwj [Line Symbols]
metapost [2019/12/08 23:41] (current)
tarquinwj Correcting subtype
Line 180: Line 180:
  
 This can be used to set a minimum pen thickness, so that all other pens take their sizes relative to that pen thickness. This can be useful for publications that mandate a specific pen width, which can be harder to control with scaling. (This can be done by setting the "​u"​ value, but that causes all symbols to be scaled too.) This can be used to set a minimum pen thickness, so that all other pens take their sizes relative to that pen thickness. This can be useful for publications that mandate a specific pen width, which can be harder to control with scaling. (This can be done by setting the "​u"​ value, but that causes all symbols to be scaled too.)
 +
 +[[user:​tarquinwj|Tarquin 2019]]
  
 <​code>​ <​code>​
Line 436: Line 438:
 The default "​anchor"​ symbol takes up a lot of space. It also resists rotation. This produces a P-hanger icon instead. It respects rotation, so that if the "​orientation"​ arrow points to the right, the P-hanger will point in the chosen direction. In addition, it selects the correct direction to face, so that the loop of the hanger always points down the page. It intentionally has a thinner line pointing into the rock, so that it appears to pierce the wall of the cave (just like a real P-hanger). The default "​anchor"​ symbol takes up a lot of space. It also resists rotation. This produces a P-hanger icon instead. It respects rotation, so that if the "​orientation"​ arrow points to the right, the P-hanger will point in the chosen direction. In addition, it selects the correct direction to face, so that the loop of the hanger always points down the page. It intentionally has a thinner line pointing into the rock, so that it appears to pierce the wall of the cave (just like a real P-hanger).
  
-In elevation view, by default it switches to being a filled circle, a standard symbol for a fixed position hanger, which can be placed on the linepoints of a basic rope line.+In elevation view, by default it switches to being a filled circle, a standard symbol for a fixed position hanger ​on [[riggingtopos|Rigging topos]], which can be placed on the linepoints of a basic rope line.
  
 By using the "-attr type" option, you can control which type of anchor it will show: By using the "-attr type" option, you can control which type of anchor it will show:
Line 609: Line 611:
 [[user:​tarquinwj|Tarquin 2019]] [[user:​tarquinwj|Tarquin 2019]]
  
-A common way to show rope lengths (at least in the UK) is with a number inside a circle. This point relies on you also including the code for [[#Adding custom styled labels at any point/​linepoint]]:​+A common way to show rope lengths (at least in the UK) on [[riggingtopos|Rigging topos]] ​is with a number inside a circle. This point relies on you also including the code for [[#Adding custom styled labels at any point/​linepoint]]:​
  
 <​code>​ <​code>​
Line 987: Line 989:
 [[user:​tarquinwj|Tarquin 2019]] [[user:​tarquinwj|Tarquin 2019]]
  
-Pits use the same appearance in both plan and elevation views. However, it may be desirable for a pit edge to be drawn as a pitch in plan view, but a ledge in elevation view. This is common with rigging ​topos, for example, where the plan uses a pit symbol, but the same same drop in the elevation view will normally be shown with a different symbol, such as a dashed line, to indicate that a traverse may be required along a ledge. It is still a pitch, so it should use the same semantic "​l_pit"​ symbol, even though the rendering should be different. This example shows how to show a pit symbol in plan view, but replace it with a dashed ledge line (borrowed from a temporary border) in elevation view:+Pits use the same appearance in both plan and elevation views. However, it may be desirable for a pit edge to be drawn as a pitch in plan view, but a ledge in elevation view. This is common with [[riggingtopos|Rigging ​topos]], for example, where the plan uses a pit symbol, but the same same drop in the elevation view will normally be shown with a different symbol, such as a dashed line, to indicate that a traverse may be required along a ledge. It is still a pitch, so it should use the same semantic "​l_pit"​ symbol, even though the rendering should be different. This example shows how to show a pit symbol in plan view, but replace it with a dashed ledge line (borrowed from a temporary border) in elevation view:
  
 <​code>​ <​code>​
Line 1010: Line 1012:
 [[user:​tarquinwj|Tarquin 2019]] [[user:​tarquinwj|Tarquin 2019]]
  
-The default Therion rope symbol is very pretty, doing fancy rebelays and anchors. This works well for simple cases, but when trying to draw rigging ​topos, it tries to add anchors and rebelays in places where you were just trying to draw Y-hang knots, and it sometimes fails to draw lines because it decides that they were too short.+The default Therion rope symbol is very pretty, doing fancy rebelays and anchors. This works well for simple cases, but when trying to draw [[riggingtopos|Rigging ​topos]], it tries to add anchors and rebelays in places where you were just trying to draw Y-hang knots, and it sometimes fails to draw lines because it decides that they were too short.
  
 It is possible to disable the anchors and rebelays by adding two options to a linepoint (not the line itself), and hoping that you never accidentally remove that particular linepoint. These options apply to the whole line rather than an individual linepoint, so you cannot fine control the use of rebelays and linepoints. It is best to just disable them, use the usual Bézier curve controls, and [[#​P-hangers that face the right way, and other anchor designs|manually add anchors]]. It is possible to disable the anchors and rebelays by adding two options to a linepoint (not the line itself), and hoping that you never accidentally remove that particular linepoint. These options apply to the whole line rather than an individual linepoint, so you cannot fine control the use of rebelays and linepoints. It is best to just disable them, use the usual Bézier curve controls, and [[#​P-hangers that face the right way, and other anchor designs|manually add anchors]].
Line 1054: Line 1056:
 [[user:​tarquinwj|Tarquin 2019]] [[user:​tarquinwj|Tarquin 2019]]
  
-For rigging ​topos, one of the most easily recognised symbols used in the UK is a rope reaching from a wall towards the main rope, with a small oval around it, pulling the rope to the side. This symbol shows an example of cutoffafter,​ used to allow the deviation'​s rope to share a linepoint with the main rope, but without showing the deviation rope inside the oval (a reverse clipping effect in MetaPost!).+For [[riggingtopos|Rigging ​topos]], one of the most easily recognised symbols used in the UK is a rope reaching from a wall towards the main rope, with a small oval around it, pulling the rope to the side. This symbol shows an example of cutoffafter,​ used to allow the deviation'​s rope to share a linepoint with the main rope, but without showing the deviation rope inside the oval (a reverse clipping effect in MetaPost!).
  
 <​code>​ <​code>​
Line 1207: Line 1209:
 [[user:​tarquinwj|Tarquin 2019]] [[user:​tarquinwj|Tarquin 2019]]
  
-Trees are often found in the entrances to caves, and sometimes a survey deserves to show the trees. This is particularly common with rigging ​topos for surface shafts, where a tree may be used as a rope belay, but it also may be in particularly large entrances which contain forests. A tree may be created as a single point symbol, but this then makes it difficult to scale the heights and widths perfectly, and even harder to attach other lines (like ropes or tethers) to the sides of them. It also means that when trying to draw a particularly distinctive tree which must be used as a belay, it is not possible to show it in a recognisable way.+Trees are often found in the entrances to caves, and sometimes a survey deserves to show the trees. This is particularly common with [[riggingtopos|Rigging ​topos]] for surface shafts, where a tree may be used as a rope belay, but it also may be in particularly large entrances which contain forests. A tree may be created as a single point symbol, but this then makes it difficult to scale the heights and widths perfectly, and even harder to attach other lines (like ropes or tethers) to the sides of them. It also means that when trying to draw a particularly distinctive tree which must be used as a belay, it is not possible to show it in a recognisable way.
  
 This is therefore a pair of symbols. The first is for the sides of the tree trunk (which could also be used to create jagged shapes for conifers), and the second is for the bushy leaves at the top of a deciduous tree. The sides of the tree can therefore be curved or branched as needed, with linepoints added for attaching rope lines, the surface lines, and the bushy part of the tree to. For plans, the bushy part alone would normally work, as a closed, circular line. This is therefore a pair of symbols. The first is for the sides of the tree trunk (which could also be used to create jagged shapes for conifers), and the second is for the bushy leaves at the top of a deciduous tree. The sides of the tree can therefore be curved or branched as needed, with linepoints added for attaching rope lines, the surface lines, and the bushy part of the tree to. For plans, the bushy part alone would normally work, as a closed, circular line.
Line 1309: Line 1311:
 {{ ::​tree.png?​nolink |}} {{ ::​tree.png?​nolink |}}
  
-Select these as line type "​u"​ with "​-subtype treetrunk"​ and "​-subtype ​treetrunk" in their options. Remember to set "-clip off" on the lines if they are going to be used outside of the cave walls. Use it with these lines in your layout:+Select these as line type "​u"​ with "​-subtype treetrunk"​ and "​-subtype ​bush" in their options. Remember to set "-clip off" on the lines if they are going to be used outside of the cave walls. Use it with these lines in your layout:
  
   text en "line u:​treetrunk"​ "​tree"​   text en "line u:​treetrunk"​ "​tree"​
Line 1325: Line 1327:
 [[user:​tarquinwj|Tarquin 2019]] [[user:​tarquinwj|Tarquin 2019]]
  
-Metal bars and wooden beams are a common part of chokes, and are not normally drawn on a survey (though sometimes that are drawn, for particularly special cases). However, sometimes they are also used for rigging, and that is where they become important. Therion does not do anything with the "​-scale"​ option on lines (it is silently ignored), but sometimes it is needed for a line symbol, and this is one of those cases - some shoring deserves a thick line, some does not. This symbol is therefore an example of how to provide an equivalent "-attr scale xs" option which can be used in the symbol code. The values it supports are the same as a regular -scale option (xs, s, m, l, xl).+Metal bars and wooden beams are a common part of chokes, and are not normally drawn on a survey (though sometimes that are drawn, for particularly special cases). However, sometimes they are also used for [[riggingtopos|rigging]], and that is where they become important. Therion does not do anything with the "​-scale"​ option on lines (it is silently ignored), but sometimes it is needed for a line symbol, and this is one of those cases - some shoring deserves a thick line, some does not. This symbol is therefore an example of how to provide an equivalent "-attr scale xs" option which can be used in the symbol code. The values it supports are the same as a regular -scale option (xs, s, m, l, xl).
  
 <​code>​ <​code>​
Line 1361: Line 1363:
  
   text en "line u:​shoring"​ "​shoring/​bars"​   text en "line u:​shoring"​ "​shoring/​bars"​
 +
 +===Centreline that is only visible when not in a scrap===
 +
 +[[user:​tarquinwj|Tarquin 2019]]
 +
 +Sometimes, you might want to show a centreline for a section of the cave where you do not have any wall data, if you are using [[tips#​Showing centreline for parts of a cave, and passage walls for others|a map made up from surveys and other maps]]. However, you might not want to show the walls within your regular scraps where you have wall data, since they are distracting and meaningless for viewers. There is no setting for this, since "​symbol-hide group centreline"​ affects all centrelines at once, so it must be done through MetaPost:
 +
 +<​code>​
 +code metapost
 +  def l_survey_cave_MY(expr P) =
 +    if ATTR__scrap_centerline:​
 +      l_survey_cave_SKBB(P);​
 +    fi;
 +  enddef;
 +  initsymbol("​l_survey_cave_MY"​);​
 +endcode
 +</​code>​
 +
 +You may notice the misleadingly named "​ATTR__scrap_centerline",​ which does not mean "​centreline within a scrap"​. Instead, it means "a virtual scrap automatically created, made up entirely of centreline",​ which is what Therion creates when you ask it to include survey data within a map.
 +
 +Use it with this line in your layout:
 +
 +  symbol-assign line survey:cave MY
 +
 +You can use a similar approach for l_survey_surface_MY (surface survey legs), p_station_temporary_MY,​ p_station_natural_MY,​ p_station_painted_MY and p_station_fixed_MY (survey stations) if you needed to show those outside too.
 ====Area Symbols==== ​ ====Area Symbols==== ​
 ===Show area water in a different color=== ===Show area water in a different color===
  • metapost.1575152097.txt.gz
  • Last modified: 2 weeks ago
  • by tarquinwj