docx

package
v0.0.0-...-3ca5dd0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 22, 2019 License: CC0-1.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FindCheckBoxTag

func FindCheckBoxTag(paragraph xml.Node) (xml.Node, error)

FindCheckBoxTag will look for a checkbox and the value tag. We look for the w:default or w:checked tag embedded in the w:checkBox tag because that is what we need to modify the checkbox.

Types

type CheckBox

type CheckBox struct {
	// contains filtered or unexported fields
}

CheckBox represents a checkbox in a word document with any corresponding text.

func NewCheckBox

func NewCheckBox(checkMark xml.Node, textNodes *[]xml.Node) *CheckBox

NewCheckBox constructs a new checkbox. Checks if the checkmark value can actually be found. If it cannot be found, will return nil.

func (*CheckBox) GetTextValue

func (c *CheckBox) GetTextValue() string

GetTextValue will return the corresponding text for the checkbox.

func (*CheckBox) IsChecked

func (c *CheckBox) IsChecked() bool

IsChecked will return true if the box is checked, false otherwise.

func (*CheckBox) SetCheckMarkTo

func (c *CheckBox) SetCheckMarkTo(value bool)

SetCheckMarkTo will set the checkbox state according to the input value.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL