diff --git a/DESCRIPTION b/DESCRIPTION index c7d7dc84..c0993844 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -1,7 +1,7 @@ Type: Package Package: flextable Title: Functions for Tabular Reporting -Version: 0.9.7.003 +Version: 0.9.7.004 Authors@R: c( person("David", "Gohel", , "david.gohel@ardata.fr", role = c("aut", "cre")), person("ArData", role = "cph"), diff --git a/NEWS.md b/NEWS.md index 36d6c54d..a2bc4b4b 100644 --- a/NEWS.md +++ b/NEWS.md @@ -4,6 +4,7 @@ - fix caption issue that came with no version of bookdown (issue #645), 'bookdown' management of caption has been simplified. +- fix vertical overlapping lines with grid output (issue #644) # flextable 0.9.6 diff --git a/R/grid_funs.R b/R/grid_funs.R index 8c9b0dc4..8924dd15 100644 --- a/R/grid_funs.R +++ b/R/grid_funs.R @@ -135,6 +135,10 @@ grid_data_add_cell_info <- function(grid_data, x) { "border.color.right", "border.width.top", "border.width.bottom" ) ] + # apply a correction to overlapping vert. borders + setorderv(fortify_borders_data, cols = c(".part", ".row_id", ".col_id")) + fortify_borders_data[fortify_borders_data$border.width.right == shift(fortify_borders_data$border.width.left, type = "lead", fill = -1), + c("border.width.right") := 0, by = c(".part", ".row_id")] cell_data <- cell_data[, .SD, .SDcols =