|
libfossil
|
An instance of this class is used to convey certain state to fsl_dibu objects. More...
#include "util.h"
Data Structures | |
| struct | fsl_dibu_opt_ansi |
| EXPERIMENTAL AND SUBJECT TO CHANGE. More... | |
Data Fields | |
| struct fsl_dibu_opt::fsl_dibu_opt_ansi | ansiColor |
| unsigned short | columnWidth |
| Maximum column width hint for side-by-side, a.k.a. | |
| unsigned short | contextLines |
| Number of lines of diff context (number of lines common to the LHS and RHS of the diff). | |
| uint32_t | diffFlags |
| Flags from the fsl_diff2_flag_e enum. | |
| const char * | hashLHS |
| The hash of the object represented by the LHS of the diff. | |
| const char * | hashRHS |
| The hash of the object represented by the RHS of the diff. | |
| const char * | nameLHS |
| The filename of the object represented by the LHS of the diff. | |
| const char * | nameRHS |
| The filename of the object represented by the LHS of the diff. | |
| fsl_output_f | out |
| Output destination. | |
| void * | outState |
| State for this->out(). | |
An instance of this class is used to convey certain state to fsl_dibu objects.
Some of this state is configuration provided by the client and some is volatile, used for communicating common state to diff builder instances during the diff rendering process.
Certain fsl_dibu implementations may require that some ostensibly optional fields be filled out. Documenting that is TODO, as the builders get developed.
| struct fsl_dibu_opt::fsl_dibu_opt_ansi fsl_dibu_opt::ansiColor |
| unsigned short fsl_dibu_opt::columnWidth |
Maximum column width hint for side-by-side, a.k.a.
split, diffs.
FSL_DIBU_SPLIT_TEXT truncates its content columns (as opposed to line numbers and its modification marker) to, at most, this width. By default it uses as much width as is necessary to render whole lines. It treats this limit as UTF8 characters, not bytes.
This is a hint, not a rule. A given diff builder is free to ignore it or to ignore values which are arbitrarily deemed "too small" or "too large."
| unsigned short fsl_dibu_opt::contextLines |
| uint32_t fsl_dibu_opt::diffFlags |
Flags from the fsl_diff2_flag_e enum.
| const char* fsl_dibu_opt::hashLHS |
| const char* fsl_dibu_opt::hashRHS |
| const char* fsl_dibu_opt::nameLHS |
| const char* fsl_dibu_opt::nameRHS |
| fsl_output_f fsl_dibu_opt::out |
Output destination.
Any given builder might, depending on how it actually constructs the diff, buffer output and delay calling this until its finish() method is called.
Note that not all diff builders use this. e.g. a diff builder which outputs to an ncurses widget cannot do so via this method and instead has to use the drawing methods of that API. Thus is is legal for this method to be NULL for some builders.
| void* fsl_dibu_opt::outState |