KnowledgeHub
Questions
Tags
Users
Search
Alex Rivera
|
Logout
Edit Question
Title
Body
I'm trying to draw a horizontal line across my diagram. The Y coordinate of the line should be halfway between points a and b (a is below b). The left and right endpoints of the line are on the bounding box of the tikzpicture. Here's how I'm doing this now, using the intersection operator: \coordinate (h0) at ($(a.north)!0.5!(b.south)$); \draw (h0 -| current bounding box.west) -- (h0 -| current bounding box.east); This strikes me as rather roundabout. What I'd rather do is get the Y coordinate of (h0) and the X coordinates of the east and west sides of the bounding box, and compose the coordinates myself. I'd like to do this, but it isn't supported syntax: \coordinate (h0) at ($(a.north)!0.5!(b.south)$); \draw (current bounding box.west.x,h0.y) -- (current bounding box.east.x,h0.y); Is there a way to reference individual components of coordinates that I'm missing?
Tags (comma-separated)
Save Edits
Cancel