文字理由 [英] text justification

查看:49
本文介绍了文字理由的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

你好,

有没有人可以指点一些代码来做文本

修复固定字体的理由,比如nroff在联机帮助页上做的那些?

谢谢,

加埃塔诺

Hello,
can anyone point me to some piece of code that do text
justification of fixed fonts like those that nroff do on manpages?
Thanks,
Gaetano

推荐答案

ga *********** @ yahoo.it 写道:

你好,

任何人都可以指点一些代码来做文本

修复固定字体的理由,就像nroff在联机帮助页上做的那样?

谢谢,
Hello,
can anyone point me to some piece of code that do text
justification of fixed fonts like those that nroff do on manpages?
Thanks,



你是否试图找到nroff的源代码?

Have you tried to find the source code of nroff?


在文章< 11*********************@t8g2000prg.googlegroups.c om>,

< ga ******** ***@yahoo.itwrote:
In article <11*********************@t8g2000prg.googlegroups.c om>,
<ga***********@yahoo.itwrote:

>您好,
任何人都可以指点我做一些文字的代码
理由固定字体,如nroff在联机帮助页上做的那些?
谢谢,

加埃塔诺
>Hello,
can anyone point me to some piece of code that do text
justification of fixed fonts like those that nroff do on manpages?
Thanks,
Gaetano



我不明白为什么你需要证明固定字体的合理性。当这样的问题出现时,如果这个问题是

标准建议,如果你不喜欢它们,那么就不要使用它们。

I don''t understand why you need to justify fixed fonts. As is the
standard advice in this ng when such questions arise, if you don''t like
them, just don''t use them.


在文章< 11 ********************* @ t8g2000prg.googlegroups.c om>中,

< ga *********** @ yahoo.itwrote:
In article <11*********************@t8g2000prg.googlegroups.c om>,
<ga***********@yahoo.itwrote:

>任何人都可以指点我一些代码,用于修复固定字体的文本,就像nroff在联机帮助页上做的那样?
>can anyone point me to some piece of code that do text
justification of fixed fonts like those that nroff do on manpages?



好​​吧,nroff的代码应该很容易找到(查找

groff,这是最广泛使用的实现)。 br />

但我建议不要使用固定宽度字体。这很难

难以阅读。


如果你真的想这样做,你可以用尽可能多的单词来填充这一行。

将适合,然后在

差距中分配所需数量的额外空格。您可以使用Bressenham的算法版本(试试Google)




- Richard

- -

考虑在一些字母表中需要多达32个字符

- 1963年的X3.4。

Well, the code for nroff should be easy enough to find (look for
groff, the most widely-used implementation).

But I recommend not justifying with fixed width fonts. It''s much
harder to read.

If you really want to do it, you fill the line with as many words as
will fit, then distribute the required number of extra spaces in the
gaps. You might use a version of Bressenham''s algorithm (try Google)
for this.

-- Richard
--
"Consideration shall be given to the need for as many as 32 characters
in some alphabets" - X3.4, 1963.


这篇关于文字理由的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆