Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add type blanks and not blanks to conditional formatting. fixes #179 #311

Conversation

vkatti
Copy link
Contributor

@vkatti vkatti commented Jan 10, 2022

Addresses Issue #179

  1. Added new type='blanks' and type='notBlanks' in the conditionalFormatting function.
  2. Added 3 tests for same.

@vkatti
Copy link
Contributor Author

vkatti commented Jan 10, 2022

Hi @ycphs, I am not sure what do I need to do to fix the failing checks for macOS. Request your guidance. Thanks.

My session info is as follows:
R version 4.1.0 (2021-05-18)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows 10 x64 (build 19044)

Matrix products: default

locale:
[1] LC_COLLATE=English_United States.1252 LC_CTYPE=English_United States.1252
[3] LC_MONETARY=English_United States.1252 LC_NUMERIC=C
[5] LC_TIME=English_United States.1252

attached base packages:
[1] stats graphics grDevices utils datasets methods base

other attached packages:
[1] openxlsx_4.2.5

loaded via a namespace (and not attached):
[1] zip_2.2.0 Rcpp_1.0.7 pillar_1.6.4 compiler_4.1.0
[5] prettyunits_1.1.1 remotes_2.4.2 tools_4.1.0 digest_0.6.29
[9] testthat_3.1.1 pkgbuild_1.3.1 pkgload_1.2.4 memoise_2.0.1
[13] lifecycle_1.0.1 tibble_3.1.6 pkgconfig_2.0.3 rlang_0.4.12
[17] cli_3.1.0 rstudioapi_0.13 commonmark_1.7 curl_4.3.2
[21] xopen_1.0.0 xfun_0.29 fastmap_1.1.0 withr_2.4.3
[25] stringr_1.4.0 roxygen2_7.1.2 knitr_1.37 xml2_1.3.3
[29] desc_1.4.0 fs_1.5.2 vctrs_0.3.8 devtools_2.4.3
[33] rprojroot_2.0.2 glue_1.6.0 R6_2.5.1 processx_3.5.2
[37] fansi_0.5.0 rcmdcheck_1.4.0 sessioninfo_1.2.2 callr_3.7.0
[41] purrr_0.3.4 magrittr_2.0.1 codetools_0.2-18 ps_1.6.0
[45] ellipsis_0.3.2 usethis_2.1.5 utf8_1.2.2 stringi_1.7.6
[49] cachem_1.0.6 crayon_1.4.2

@JanMarvin
Copy link
Collaborator

Hi @vkatti , don't worry. Apparently this test fails Mac. Maybe they don't allow internet access anymore. We can try to disable it if internet access is not available. It's not all that important.

xlsxFile <- "https://github.com/ycphs/openxlsx/raw/master/inst/extdata/readTest.xlsx"

@vkatti
Copy link
Contributor Author

vkatti commented Jan 10, 2022

Oh OK. So... is there anything I need to do further?

@JanMarvin
Copy link
Collaborator

No, nothing to do right now. Just wait until someone can review the pull request. Thanks for the pull request!

@JanMarvin JanMarvin changed the title Add type blanks and not blanks to conditional formatting Add type blanks and not blanks to conditional formatting. fixes #179 Jan 18, 2022
@JanMarvin JanMarvin merged commit a4c6072 into ycphs:master Jan 18, 2022
@JanMarvin
Copy link
Collaborator

Thank you for your contribution!

netbsd-srcmastr pushed a commit to NetBSD/pkgsrc that referenced this pull request Jan 4, 2025
# openxlsx 4.2.7.1

* It's now possible to insert a hyperlinked image by passing a URL,
  relative or absolute file path, or mailto string to the new
  `address` parameter of `insertImage()`.

# openxlsx 4.2.7

* Fixed warning on `dataValidation(..., type = "list")`
  ([#342](ycphs/openxlsx#342))

* Added optional argument to `loadWorkbook` to decide if empty/blank
  cells should be converted to NA_character_ (the default) or left
  blank as is

* `saveWorkbook()` now succeeds when called after the user has set
  column widths for a range of columns (e.g. 1:2), saved the workbook,
  then set column widths for a new range that is inclusive of the
  previous one (e.g. 1:5)
  ([#493](ycphs/openxlsx#493)).

## Improvements

* Improve detectDates
  ([#288](ycphs/openxlsx#288))

* Preserve window size and position, also `getWindowSize()` and
  `setWindowSize()`
  ([466](ycphs/openxlsx#466))

# openxlsx 4.2.6

* Fix external links
  ([#410](ycphs/openxlsx#410))

* Do not add unneccessary sheetPr node
  ([#409](ycphs/openxlsx#409))

* Add support for `namedRegion`s having dots and other special
  characters ([#338](ycphs/openxlsx#338)).

* Add type blanks and not blanks to conditional formatting
  ([#311](ycphs/openxlsx#311))

# openxlsx 4.2.5

## Fixes

* `openxlsx_setOp()` now works with named list
  ([#215](ycphs/openxlsx#215))

* `loadWorkbook()` imports `inlineStr`. Values remain `inlineStr` when
  writing the workbook with `saveWorkbook()`. Similar `read.xlsx` and
  `readWorkbook` import `inlineStr`.

* `read.xlsx()` no longer changes random seed
  ([#183](ycphs/openxlsx#183))

* fixed a regression that caused fonts to be read in incorrectly
  ([#207](ycphs/openxlsx#207))

* add option to save as read only recommended
  ([#201](ycphs/openxlsx#201))

* fixed writing hyperlink formulas
  ([#200](ycphs/openxlsx#200))

* `write.xlsx()` now throws an error if it doesn't have write
  permissions ([#190](ycphs/openxlsx#190))

* `write.xlsx()` now again uses the default of `overwrite = TRUE` for
  saving files ([#249](ycphs/openxlsx#249))

* `as.character.formula()` exported to warn about potential conflicts
  with other packages
  ([#312](ycphs/openxlsx#312),
  [#315](ycphs/openxlsx#315))

## Improvements

* `options()` are more consistently set in functions (see:
  [#289](ycphs/openxlsx#262))

* `Workbook$show()` no longer fails when called in a 0 sheet
  workbook([#240](ycphs/openxlsx#240))

* `read.xlsx()` again accepts `.xlsm` files
([#205](ycphs/openxlsx#205),
[#209](ycphs/openxlsx#209))

* `makeHyperlinkString()` does no longer require a sheet argument
  ([#57](ycphs/openxlsx#57),
  [#58](ycphs/openxlsx#58))

* improvements in how `openxlsx` creates temporary directories (see
  [#262](ycphs/openxlsx#262))

* `writeData()` calls `force(x)` to evaluate the object before options
  are set ([#264](ycphs/openxlsx#264))

* `createComment()` now correctly handles `integers` in `width` and
  `height` ([#275](ycphs/openxlsx#275))

* `setStyles()` accepts `halign="justify"`
  ([#305](ycphs/openxlsx#305))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants