Change default to print space after the approximation tilde

Added config("tilde_space", boolean).  The "tilde_space" controls
whether or not a space (' ') is printed after leading tilde ('~').
By default, config("tilde_space") is true, which is a change
from past behavior.  For example, now:

    ; 1/3
	    ~ 0.33333333333333333333

With config("tilde_space", 0):

    ; 1/3
	    ~0.33333333333333333333

To disable "tilde_space", use config("tilde_space", 0) on the
command line and/or use config("tilde_space", 0),; in your ~/.calcrc.
Thanks goes to <GitHub use ljramalho> for this suggestion.

Added config("tilde_space", boolean) to help/config, along with
a few few minor text improvements.  Updated cal/regress to test
config("tilde_space") and to account for the new default.
This commit is contained in:
Landon Curt Noll
2022-12-03 12:22:55 -08:00
parent 83adfaa720
commit 0d99ba54d8
9 changed files with 156 additions and 55 deletions

View File

@@ -439,6 +439,7 @@ config_hash(CONFIG *cfg, QCKHASH val)
value = (((value>>5) | (value<<27)) ^ (USB32)cfg->pow2);
value = (((value>>5) | (value<<27)) ^ (USB32)cfg->redc2);
value = (((value>>5) | (value<<27)) ^ (USB32)cfg->tilde_ok);
value = (((value>>5) | (value<<27)) ^ (USB32)cfg->tilde_space);
value = (((value>>5) | (value<<27)) ^ (USB32)cfg->tab_ok);
value = (((value>>5) | (value<<27)) ^ (USB32)cfg->quomod);
value = (((value>>5) | (value<<27)) ^ (USB32)cfg->quo);