Working with Word documents

read_docx() print(<rdocx>)

Create a 'Word' document object

set_doc_properties()

set document properties

change_styles()

Replace Styles in a Word Document

Word documents information

docx_summary()

get Word content in a data.frame

styles_info()

read Word styles

doc_properties()

read document properties

docx_dim()

Word page layout

docx_show_chunk()

Show underlying text tag structure

Navigate into Word documents

cursor_begin() cursor_bookmark() cursor_end() cursor_reach() cursor_forward() cursor_backward()

set cursor in an rdocx object

docx_bookmarks()

List Word bookmarks

Add content to Word documents

body_add_img()

add image

body_add_par()

add paragraph of text

body_add_table()

add table

body_add_blocks()

add a list of blocks into a document

body_add_fpar()

add fpar

body_add_toc()

add table of content

body_add_break()

add page break

body_add_docx()

insert an external docx

body_bookmark()

add bookmark

body_add_gg()

add ggplot

body_add_caption()

add Word caption

body_add_plot()

add plot

body_end_block_section()

add any section

body_set_default_section()

Define Default Section

body_end_section_columns()

add multi columns section

body_end_section_columns_landscape()

add multi columns section within landscape orientation

body_end_section_continuous()

add continuous section

body_end_section_landscape()

add landscape section

body_end_section_portrait()

add portrait section

Word sections

prop_section()

section properties

page_mar()

page margins object

page_size()

page size object

section_columns()

section columns

Word simple tables

prop_table()

Table properties

table_colwidths()

Column widths of a table

table_conditional_formatting()

Table conditional formatting

table_layout()

Algorithm for table layout

table_stylenames()

Paragraph styles for columns

table_width()

Preferred width for a table

Replace content in Word documents

body_replace_text_at_bkm() body_replace_img_at_bkm() headers_replace_text_at_bkm() headers_replace_img_at_bkm() footers_replace_text_at_bkm() footers_replace_img_at_bkm()

replace text at a bookmark location

body_replace_all_text() headers_replace_all_text() footers_replace_all_text()

Replace text anywhere in the document, or at a cursor

Remove content from Word documents

body_remove()

remove an element

Reading/writing PowerPoint documents

read_pptx()

open a connexion to a 'PowerPoint' file

print(<rpptx>)

write a 'PowerPoint' file.

Manipulate slides

add_slide()

add a slide

on_slide()

change current slide

move_slide()

move a slide

remove_slide()

remove a slide

Slide content

ph_with()

add objects into a new shape on the current slide

ph_location()

create a location for a placeholder

ph_location_fullsize()

location of a full size element

ph_location_label()

location of a named placeholder

ph_location_left()

location of a left body element

ph_location_right()

location of a right body element

ph_location_template()

create a location for a placeholder based on a template

ph_location_type()

location of a placeholder based on a type

ph_slidelink()

slide link to a placeholder

ph_hyperlink()

hyperlink a placeholder

ph_remove()

remove a shape

Read PowerPoint information

pptx_summary()

get PowerPoint content in a data.frame

slide_size()

slides width and height

length(<rpptx>)

number of slides

annotate_base()

PowerPoint placeholder parameters annotation

layout_summary()

presentation layouts summary

layout_properties()

slide layout properties

plot_layout_properties()

Plot slide layout properties

slide_summary()

get PowerPoint slide content in a data.frame

color_scheme()

color scheme

media_extract()

Extract media from a document object

Content formatting

Define formatted paragraphs or parts of paragraphs, such as text, calculated Word fields, sets of paragraphs, etc.

fpar() update(<fpar>)

Concatenate formatted text as a paragraph

block_caption()

Caption block

block_list()

List of blocks

block_pour_docx()

Pour external Word document in the current document

block_section()

New Word section

block_table()

Table block

block_toc()

Table of content

unordered_list()

Unordered list

plot_instr()

Wrap plot instructions for png plotting in Powerpoint or Word

ftext()

formatted chunk of text

run_autonum()

auto number

run_bookmark()

bookmark for Word

run_columnbreak()

column break

run_linebreak()

page break for Word

run_pagebreak()

page break for Word

run_reference()

reference

run_word_field() run_seqfield()

seqfield

external_img()

external image

empty_content()

create empty blocks

Formatting properties

fp_text() format(<fp_text>) print(<fp_text>) update(<fp_text>)

Text formatting properties

fp_par() print(<fp_par>) update(<fp_par>)

Paragraph formatting properties

fp_border() update(<fp_border>)

border properties object

fp_cell() format(<fp_cell>) print(<fp_cell>) update(<fp_cell>)

Cell formatting properties