docx_show_chunk: Show underlying text tag structure

Description Usage Arguments See Also Examples

View source: R/docx_replace.R

Description

Show the structure of text tags at the current cursor. This is most useful when trying to troubleshoot search-and-replace functionality using body_replace_all_text.

Usage

1

Arguments

x

a docx device

See Also

body_replace_all_text

Examples

1
2
3
4
5
6
7
8
library(magrittr)

doc <- read_docx() %>%
  body_add_par("Placeholder one") %>%
  body_add_par("Placeholder two")

# Show text chunk at cursor
docx_show_chunk(doc)  # Output is 'Placeholder two'

officer documentation built on July 24, 2018, 9:02 a.m.