~kchibisov

~kchibisov/public-inbox

Last active 4 years ago
View more

Recent activity

[PATCH scdoc v3] Emit \(ti and \(ha instead of ~ and ^ 3 months ago

From Kirill Chibisov to ~sircmpwn/public-inbox

Groff since 1.23 maps '^' and '~' by default to U+02C6 and U+02DC
respectively.

The suggestion in groff_man_style(7) is to use \(ti and \(ha when the
latin variants are desired.

Links: https://lists.gnu.org/archive/html/info-gnu/2023-07/msg00001.html
---
 src/main.c                |  8 ++++++++
 test/character-substitute | 18 ++++++++++++++++++
 2 files changed, 26 insertions(+)
 create mode 100755 test/character-substitute

diff --git a/src/main.c b/src/main.c
[message trimmed]

Re: [PATCH scdoc v1] Emit \(ti and \(ha instead of ~ and ^ 3 months ago

From Kirill Chibisov to ~sircmpwn/public-inbox

> s/ta/to
>
> and I think it's tilde, not tilda.

yeah, indeed, though, I already have v2 fixing the first typo and adding
a test, will send v3 for s/tilda/tilde/.

-- 
Kind Regards,
Kirill Chibisov

[PATCH scdoc v2] Emit \(ti and \(ha instead of ~ and ^ 3 months ago

From Kirill Chibisov to ~sircmpwn/public-inbox

Groff since 1.23 maps '^' and '~' by default to U+02C6 and U+02DC
respectively.

The suggestion in groff_man_style(7) is to use \(ti and \(ha when the
latin variants are desired.

Links: https://lists.gnu.org/archive/html/info-gnu/2023-07/msg00001.html
---
Haven't noticed that there's a test framework.
 src/main.c                |  8 ++++++++
 test/character-substitute | 18 ++++++++++++++++++
 2 files changed, 26 insertions(+)
 create mode 100755 test/character-substitute
[message trimmed]

Re: [PATCH scdoc v1] Emit \(ti and \(ha instead of ~ and ^ 3 months ago

From Kirill Chibisov to ~sircmpwn/public-inbox

>  			break;
> +		case '~':
> +			// Escape tilda ta not make it render with U+02DC
> +			fprintf(p->output, "\\(ti");
> +			break;
> +		case '^':
> +			// Escape caret ta not make it render with U+02C6
> +			fprintf(p->output, "\\(ha");
> +			break;

I'd add a note that having those characters inside the header won't work
(unicode characters will still be emitted), but I guess a lot of stuff
doesn't work in headers, since parse_text path is not used for the
header text parsing.

[PATCH scdoc v1] Emit \(ti and \(ha instead of ~ and ^ 3 months ago

From Kirill Chibisov to ~sircmpwn/public-inbox

Groff since 1.23 maps '^' and '~' by default to U+02C6 and U+02DC
respectively.

The suggestion in groff_man_style(7) is to use \(ti and \(ha when the
latin variants are desired.

Links: https://lists.gnu.org/archive/html/info-gnu/2023-07/msg00001.html
---
 src/main.c | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/src/main.c b/src/main.c
index a49cb40..56d4238 100644
--- a/src/main.c
[message trimmed]

Re: [issue scdoc] tilde and caret handling 7 months ago

From Kirill Chibisov to ~sircmpwn/public-inbox

> I'm into doing this automatically, if you'd care to send a patch?

I can if you can point me to place the logic should likely go.

> When were \(ti etc introduced?

Judging by groff's git history, both ha and ti were present in 2001, so
I guess it's fine. Maybe even earlier.

-- 
Kind Regards,
Kirill Chibisov

[issue scdoc] tilde and caret handling 9 months ago

From Kirill Chibisov to ~sircmpwn/public-inbox

Groff 1.23 now maps '^' (caret) and '~' (tilde) to U+02C6 and U+02DC
respectively [1](search for tilde).

The suggestion in groff_man_style(7) is to use \(ti and \(ha , if the
latin variants are desired.

It would be nice if scdoc had an option (or did that automatically) to
emit latin tilde/caret, so users don't have to rely on `sed`-ing the end
output. It's also could be surprising for some users that tilde/caret is
rendered as some unicode on some users' machines and it's not that
trivial to figure out.

[1] - https://lists.gnu.org/archive/html/info-gnu/2023-07/msg00001.html

Re: [PATCH aerc] colorize: only emit osc8 if [general].enable-osc8=true 1 year, 3 months ago

From Kirill Chibisov to ~rjarry/aerc-devel

Acked-by: Kirill Chibisov <contact@kchibisov.com>

-- 
Kind Regards,
Kirill Chibisov

Re: [PATCH aerc v3] filters/colorize: emit OSC 8 for URLs and emails 1 year, 3 months ago

From Kirill Chibisov to ~rjarry/aerc-devel

> Would that be so bad if it was opt-in instead of opt-out? That way, it
> would be consistent with the aerc.conf [general].enable-osc8 setting.

I don't really care, you can pick opt-out. It just you can find even more
broken less in the wild, which doesn't pass even colors.

-- 
Kind Regards,
Kirill Chibisov

Re: [PATCH aerc v3] filters/colorize: emit OSC 8 for URLs and emails 1 year, 3 months ago

From Kirill Chibisov to ~rjarry/aerc-devel

> > % echo 'https://openbsd.org' | /usr/local/libexec/aerc/filters/colorize
> > https://openbsd.orghttps://openbsd.org
> >
> > > It's also
> > > possible the pager is mangling output...aerc will pass to less -Rc by default.
> > > Maybe OpenBSD less doesn't handle OSC8??
> >
> > I can also reproduce the issue outside of aerc by piping to less -Rc.
> > Thanks for the pointer, I would have never think of less.
>
> That is a strong argument for having the OSC-8 URLs opt-in for the
> colorize filter. This could go in the stylesets:
>
>     [viewer]