不断的连字符

编程入门 行业动态 更新时间:2024-10-12 22:25:55
本文介绍了不断的连字符的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

您好。我在尝试学习是否存在这样的东西时发现了以下内容: 非破坏连字符。显然,Unicode有一个 - 但这并不是很好的支持,特别是在旧版浏览器中。有人在某处说: 或者,您可以使用CSS声明一个类: ..nowrap {white-space:nowrap} ....然后将复合词包装在< span class = nowrap>< / span>中标记(或 任何其他合适的内联标记)。你也可以尝试{white-space:pre} ... 我不知道在哪里发布这个,因为部分问题是关于 字符实体显然未在html中定义?然而,对于非包装的CSS想法呢? 怎么样?在我的一个页面上 www.TheBicyclingGuitarist/newstuff.htm我赞赏 comp.infosystems的一些人。 www .authoring.site设计。我希望连字符介于 网站和设计之间是一个非破坏性的。 Chris Watson又称骑自行车的吉他手

Hi. I found the following when trying to learn if there is such a thing as a non-breaking hyphen. Apparently Unicode has a ‑ but that is not well-supported, especially in older browsers. Somebody somewhere said: Alternately, you can use CSS to declare a class having: ..nowrap { white-space:nowrap } .... and then wrap the compound word in a <span class=nowrap></span> tag (or any other suitable inline tag). You can also try { white-space:pre } ... I wasn''t sure where to post this, because part of the question is about the character entity that apparently is NOT defined in html? However, what about the CSS idea for non-wrapping? On one of my pages www.TheBicyclingGuitarist/newstuff.htm I give credit to some folks at comp.infosystems.www.authoring.site-design. I want the hyphen in between site and design to be a non-breaking one. Chris Watson a.k.a. "The Bicycling Guitarist"

推荐答案

2004年11月12日星期五18:19:08 GMT,骑自行车的吉他手 < Ch ** *@TheBicyclingGuitarist>写道: On Fri, 12 Nov 2004 18:19:08 GMT, The Bicycling Guitarist <Ch***@TheBicyclingGuitarist> wrote: 嗨。当我试图学习是否有这样的东西作为一个不断的连字符时,我发现了以下内容。显然,Unicode有一个 - 但是并没有得到很好的支持,特别是在旧的浏览器中。有人在某地说: 或者,您可以使用CSS来声明一个类: .nowrap {white-space:nowrap} Hi. I found the following when trying to learn if there is such a thing as a non-breaking hyphen. Apparently Unicode has a ‑ but that is not well-supported, especially in older browsers. Somebody somewhere said: Alternately, you can use CSS to declare a class having: .nowrap { white-space:nowrap }

你可以做到这一点。还有其他解决方案。我使用< nobr>那些有 的东西留在一行< / nobr>。当然,W3C验证器会一直警告 < nobr>不是HTML4.01中的有效元素。如果你被验证者唠叨这个问题,那就写下你自己的DTD吧。我做到了。验证器是 现在对我很好;-)。 - PretLetters< http:// home .wanadoo.nl / b.de.zoete /> Webontwerp< home.wanadoo.nl/b.de.zoete/html/webontwerp.html> Zweefvliegen< home.wanadoo.nl/b.de.zoete/html/vliegen.html> DTD< home.wanadoo.nl/ b.de.zoete / dtd / not_so_strict.dtd>

You can do that. There are other solutions. I use <nobr>the stuff that has to stay in one line</nobr>. Sure, the W3C-validator keeps warning that <nobr> is not a valid element in HTML4.01. If you get bugged by this nagging by the validator, just write your own DTD. I did. The validator is very nice to me now ;-) . -- PretLetters <home.wanadoo.nl/b.de.zoete/> Webontwerp <home.wanadoo.nl/b.de.zoete/html/webontwerp.html> Zweefvliegen <home.wanadoo.nl/b.de.zoete/html/vliegen.html> DTD <home.wanadoo.nl/b.de.zoete/dtd/not_so_strict.dtd>

2004年11月12日星期五18:19:08 GMT,骑自行车的吉他手 < Ch *** @ TheBicyclingGuitarist>写道: On Fri, 12 Nov 2004 18:19:08 GMT, "The Bicycling Guitarist" <Ch***@TheBicyclingGuitarist> wrote: 嗨。在尝试学习是否存在非断裂连字符时,我发现了以下内容。显然,Unicode有一个 - 但是并没有得到很好的支持,特别是在旧的浏览器中。有人在某处说: 或者,您可以使用CSS声明一个类: .nowrap {white-space:nowrap} 。 ..然后将复合词包装在< span class = nowrap>< / span>中标签(或任何其他合适的内联标签)。你也可以尝试{white-space:pre} ... 我不知道在哪里发布这个,因为部分问题是关于字符实体,显然是没有在html中定义?然而,对于非包装的CSS想法呢?在我的一个页面上 www.TheBicyclingGuitarist/newstuff.htm我赞赏 comp.infosystems的一些人。 www.authoring.site - 设计。我希望网站和设计之间的连字符是一个不破坏的连字符。 Hi. I found the following when trying to learn if there is such a thing as anon-breaking hyphen. Apparently Unicode has a ‑ but that is notwell-supported, especially in older browsers. Somebody somewhere said:Alternately, you can use CSS to declare a class having:.nowrap { white-space:nowrap }... and then wrap the compound word in a <span class=nowrap></span> tag (orany other suitable inline tag). You can also try { white-space:pre } ...I wasn''t sure where to post this, because part of the question is about thecharacter entity that apparently is NOT defined in html? However, what aboutthe CSS idea for non-wrapping? On one of my pageswww.TheBicyclingGuitarist/newstuff.htm I give credit to some folks atcomp.infosystems.www.authoring.site-design. I want the hyphen in betweensite and design to be a non-breaking one.

使用CSS空白:nowrap似乎在浏览器中运行良好最近都是 。然而,有一个小的混乱因素:CSS2规范 表示空白区域仅适用于块级元素。对于 white-space:pre这是明智的,对于white-space:nowrap它是愚蠢的。 但是浏览器编写者似乎已经决定忽略那一行 spec并做一些明智的事情。 (AFAIK) - Stephen Poley www.xs4all.nl/~sbpoley/webmatters/

Stephen Poley< sb ****************** @ xs4all.nl>写道: Stephen Poley <sb******************@xs4all.nl> wrote: 使用CSS white-space:nowrap似乎在最近的浏览器中运行良好。 是的,当CSS启用时。 然而有一个小小的混乱因素:CSS2规范说白色空间仅适用于块级元素。 Using CSS white-space:nowrap seems to work well in browsers that are at all recent. Yes, when CSS is enabled. There is however a small confusion factor: the CSS2 spec says that white-space only applies to block-level elements.

长期以来人们都说这是一个错误,他们可能没有b $ b意思是这么说。但由于W3C的流程,W3C 建议目前是CSS2规范,但W3C真的_means_那个 每个人都应该使用CSS 2.1草案(Proposed建议。 财产含义的措辞也含糊不清,特别是如果你想到白色空间这个名字的话。连字符不是白色空间 当然。 - Yucca, www.cs.tut.fi/~jkorpela/ 关于网站创作的网页: http://www.cs.tut .fi / ~jkorpela / www.html

It has long been said that this was a mistake and they probably didn''t mean to say so. But due to the processes of the W3C, the W3C recommendation is currently the CSS2 spec but the W3C really _means_ that everyone should use the CSS 2.1 draft ("Proposed Recommendation"). The wording of the meaning of the property is vague too, especially if you think about the name white-space. Hyphens aren''t white space of course. -- Yucca, www.cs.tut.fi/~jkorpela/ Pages about Web authoring: www.cs.tut.fi/~jkorpela/www.html

更多推荐

不断的连字符

本文发布于:2023-11-29 13:41:44,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1646542.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:字符

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!