groff
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Find a char in string


From: John Ankarström
Subject: Re: Find a char in string
Date: Mon, 5 Jul 2021 21:50:44 +0200
User-agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:38.0) Gecko/20100101 Thunderbird/38.5.0

Den 2021-06-23 kl. 21:48 skrev Wim Stockman:
> Is there a function in groff to find the position of a char in a string.
> So I can split a string into more than one.
> I found the substring function that can cut based on length. If I could my
> marker in the string I could cut it there.

Heirloom troff has an .index request:

.index R xx string : Store position where string occurs in xx in register R

Perhaps it should be considered for inclusion in groff.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]