Skip to content

Commit

Permalink
Fix #227
Browse files Browse the repository at this point in the history
  • Loading branch information
thomasp85 committed Jan 11, 2024
1 parent 3186ec4 commit 5fc1ba7
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 2 additions & 0 deletions NEWS.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

* Fix a precision bug in circle pack layout (#345)
* `GeomEdgeTile` now uses `edge_width` instead of `edge_size` for the border
* Fix a bug in `geom_edge_parallel()` when used with edge labels. Edges are now
correctly offset, though label may still overlap (#227)

# ggraph 2.1.0

Expand Down
2 changes: 1 addition & 1 deletion R/geom_edge.R
Original file line number Diff line number Diff line change
Expand Up @@ -223,7 +223,7 @@ GeomEdgeParallelPath <- ggproto('GeomEdgeParallelPath', GeomEdgePath,
label_dodge = label_dodge,
label_push = label_push)
if (inherits(panel, 'gList')) {
panel[[1]]$sep <- (data$.position * sep)[panel[[1]]$id]
panel[[1]]$sep <- (data$.position[!duplicated(data$group)] * sep)[panel[[1]]$id]
class(panel[[1]]) <- c('parallelPath', class(panel[[1]]))
} else {
panel$sep <- (data$.position[!duplicated(data$group)] * sep)[panel$id]
Expand Down

0 comments on commit 5fc1ba7

Please sign in to comment.