Skip to content

disp.width calcs with width changing styles #65

Open
@brodieG

Description

@brodieG

Notice how disp.width does not help in the least avoid wrapping:

> my.pal <- PaletteOfStyles()
> my.style <- StyleRaw()   # See `?Style` for custom styles
> my.style@funs@word.delete <- function(x) sprintf("--%s--", x)
> my.pal["ansi256", "light", "rgb"] <- list(my.style) # note `list()`
> ## Output has no format now for format/color.mode/brightness
> ## we modified ...
> ## `pager="off"` for CRAN compliance; you may omit in normal use
> diffPrint(
+    1:3, 2:5, format="ansi256", color.mode="rgb", brightness="light",
+    palette.of.styles=my.pal, pager="off", disp.width=80
+ )
< --1:3--      > 2:5        
@@ 1 @@        @@ 1 @@      
< [1] --1-- 2  > [1] 2 3 4 5
:  3           ~            

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions