</div>
</div>
safjaskflasjfklsajfklasjflksajflksjflkasjfksafj
<div class=c5>
滿是中文的情形。滿是中文 翻譯情況。滿是中文的環境。 } This is all English. This is all English. This is all English. </tr>
<td class="AutoNewline">主動換行主動換行主動換行主動換行自動換行主動換行主動換行主動換行主動換行自動換行主動換行自動換行主動換行主動換行主動換行主動換行主動換行主動換行自動換行主動換行自動換行主動換行自動換行主動換行</td>
safjaskflasjfklsajfklasjflksajflksjflkasjfksafj ![]() <style type="text/css"> 強迫英文單詞斷行 <div class=c6> CSS 裡 翻譯 word-break 屬性,將其設為 break-all 便可 翻譯社 .c4{ width:300px;word-wrap:break-word;word-break:keep-all; border:1px solid blue} } </div> 中英文混排 翻譯情形。Chinese and English. 中英文混排的情形 翻譯社Chinese and English. word-wrap: 滿是中文的情況。滿是中文的情況。滿是中文的環境 翻譯社。-> 翻譯社|,-> 翻譯公司|的-> 翻譯 table-layout: fixed;
<br> <div class=c1> normal是默許情形,英文單詞不被拆開。 word-wrap同word-break的區分 ff下: </div> 也不是 </tr>.c3{ width:300px;word-wrap:break-word;word-break:break-all; border:1px solid green} safjaskflasjfklsajfklasjflksajflksjflkasjfksafj table { </div> **************增補************************ img { <div class=c3> 而不是 overflow:hidden; 中英文混排的情形 翻譯社Chinese and English. 中英文混排的情形。Chinese and English. .NoNewline全是中文的環境。滿是中文 翻譯情況。全是中文的情況。 <div class=c7> <table>目前首要的問題存在於 長串英文 和 英文單詞被斷開。其實長串英文就是一個比較長的單詞罷了。
用:overflow:auto; ie下,長串會主動折行。ff下,長串會被隱瞞。 word-break: keep-all;/*必需*/<div class=c5> 最後總結一下最適用的代碼: 以下是援用片段: |
This is all English. This is all English. This is all English.
word-wrap:break-word;
<tr>
break-all Behaves the same as normal for Asian text 翻譯公司 yet allows the line to break arbitrarily for non-Asian text. This value is suited to Asian text that contains some excerpts of non-Asian text.
This is all English. This is all English. This is all English.
div {
.AutoNewline
</style>
word-wrap: break-word;
normal Default. Content exceeds the boundaries of its container.
This is all English. This is all English. This is all English.
所以,綜上,最好 翻譯方式是word-wrap:break-word;overflow:hidden;
即英文單詞應不應該被斷開那?那問題很較著了,顯然不該該被斷開了。
![div css xhtml xml Example Source Code](https://imageproxy.pixnet.cc/imgproxy?url=https://www.dugukeji.com/mb/uploads/divcss/quote.gif)
<div class=c5>
}
</div>
使用break-word時,是將強迫換行。中文沒有任何問題,英文語句也沒問題 翻譯社然則對於長串的英文,就不起感化 翻譯社
<div class=c3>
=========彌補=================================
中英文混排的環境 翻譯社Chinese and English. 中英文混排 翻譯環境。Chinese and English.
"word-wrap:"是節制換行的。
在 我們設計網頁的時候,總會遇到一些不興奮的事情,最多見 翻譯莫過於在後台添加內容後才發現顯示 翻譯頁面被撐開,致使網頁極端不美觀。之前大師根基上都是設計表 格,網上自然很多對於的解決方式,現在還有div+css標準設計,很少看到相幹好的方式,目下當今把日常平凡找到 翻譯避免表格被撐開 翻譯好方式總結歸納一下,和人人 一路分享。
<table></div>
word-break: break-all;/*必需*/table-layout: fixed;
<div class="c2">
<br>
而不是word- wrap:break-word;word-break:break-all;。
</div>
{
</div>
P.S.若未設定 width ,則跨越螢幕畫面最右邊 翻譯字才會主動折行囉。
<div class=c2>
</div>
</div>
safjaskflasjfklsajfklasjflksajflksjflkasjfksafj
overflow: hidden; (讓多出來 翻譯不顯示。)
<div class="c5">
另:
word-wrap:break-word;
是用來強制截斷英文單字而換行 翻譯社
</div>
</div>
為領會決長串英文,一般用word-wrap:break-word;word-break:break-all;。但是,此體例會導致,通俗 的英文語句中的單詞會被斷開(ie下也是)。
</div>
<div class=c7>
在我們設計網頁的時候,總會碰到一些不興奮的工作,最多見的莫過於在後台添加內容後才發現顯示的頁面被撐開,致使網頁極端不美觀 翻譯社之前大家基本上都是設計 表格,網上天然不少對於的解決方法,現在還有div+css標準設計,很少看到相關好 翻譯方法,而今把平時找到的避免表格被撐開 翻譯好方式總結歸納一下,和大 家一起分享。
<br>
word-break:
</div>
另,測試代碼以下:
break-word Content wraps to next line, and a word-break occurs when necessary. 需要時會觸發word-break 翻譯社
break-word是節制是否斷詞 翻譯。
.c7{ width:300px;word-wrap:break-word;overflow:auto; border:1px solid yellow}
</div>
<div class="c3">
********此段為參考,還沒有試過************
若是是div層,請用:
以下是援用片段:
word-wrap:break-word; overflow:auto;
全是中文的情形。滿是中文的情況。滿是中文的情形。
.c2{ width:300px;word-wrap:break-word; border:1px solid yellow}
ie下:
以下是援用片斷:
word-wrap:break-word; word-break:break-all;
用css控制圖片自順應巨細,代碼如:
<div class="c4">
</table></div>
keep-all Does not allow word breaking for Chinese, Japanese, and Korean. Functions the same way as normal for all non-Asian languages. This value is optimized for text that includes small amounts of Chinese, Japanese 翻譯公司 or Korean.
強迫不換行
div{ white-space:nowrap; }
table-layout: fixed;
</div>
word-wrap:break-word;overflow:auto;在ie下沒有任何問題 翻譯社在ff下,長串會被遮住部門內容。
主動換行
div{ word-wrap: break-word; word-break: normal; }
This is all English. This is all English. This is all English.
<div class=c3>
總結以下:
</div>
<div class="c7">
對於長串英文,就是惡意 翻譯東西,自然不用去管了 翻譯社可是,也要想些舉措,不讓它把容器撐大。
<div class=c4>
This is all English. This is all English. This is all English.
word-break: break-all;
normal Default. Allows line breaking within words. 似乎是只對Asian text起感化。
}
.c6{ width:300px;word-break:keep-all; border:1px solid red}
如這2個都不消的話,中文不會出任何問題 翻譯社英文語句也不會出問題。但是,長串英文會出問題 翻譯社
===========================================================
</div>
</div>
<div class=c2>
</div>
{
<tr>
<br>
<div class="c6"> |
我們可以針對表格的屬性來限制巨細避免被撐開,
比如在裡添加代碼「style="table-layout:fixed;word-wrap:break-word; word-break;break-all;"」,
其中「table-layout:fixed; 」是為了將表格結構固定住,就可以有用地避免表格被撐開,
「word-wrap:break-word; 」是節制換行的,也就是強迫履行換行,這個在文本內容較多的情況下需要利用到,特別是重複的內容呈現,不執行換行的話,表格就被撐開了;
而「word- break: break-all; 」可以解決IE的框架被英文(非亞洲語言文本行)撐開的問題,
然則不會強迫換行,只顯示表格寬度裡的內容。
一般情形下只要用到 「style="table-layout:fixed;word-wrap:break-word;"」就能夠 翻譯社固然,上面挪用的語句可以定義在css 裡,好比
這時您就會發現正本應當超出 width=100 的文字卻主動折到下一行了!
</div>
1.htm
<style>
.c1{ width:300px; border:1px solid red}
.c2{ width:300px;word-wrap:break-word; border:1px solid yellow}
.c3{ width:300px;word-wrap:break-word;word-break:break-all; border:1px solid green}
.c4{ width:300px;word-wrap:break-word;word-break:keep-all; border:1px solid blue}
.c5{ width:300px;word-break:break-all; border:1px solid black}
.c6{ width:300px;word-break:keep-all; border:1px solid red}
.c7{ width:300px;word-wrap:break-word;overflow:auto; border:1px solid yellow}
</style>
.c1{ width:300px; border:1px solid red}
<div class="c1">asdasd
</div>
<div class=c1>
This is all English. This is all English. This is all English.
</div>
<div class=c1>
<br>
<div class=c4>
<div class=c6>
2、強迫不換行:
width: 加上寬度;
</table>
防止表格被撐開或div層被撐開 翻譯方式
</div>
其 中 max-width:600px; 在IE7、FireFox等其他非IE瀏覽器下最大寬度為600px,但在IE6中無效;width:600px; 在所有瀏覽器中圖片的巨細為600px,當圖片巨細大於600px,主動縮小為600px,在IE6中有用;而 overflow:hidden; 指將超越設置巨細的部分潛藏,避免節制圖片巨細失敗而引發的表格撐開變形。
1、強制換行:
</div>
中英文混排 翻譯環境。Chinese and English. 中英文混排的情形 翻譯社Chinese and English.
使用word-wrap:break-word;所有的都正常。
max-width: 600px;
<div class=c4>
最好 翻譯體例是
}
如果是表格,請用:
safjaskflasjfklsajfklasjflksajflksjflkasjfksafj
相容 IE 和 FF 的換行 CSS 保舉樣式
.c5{ width:300px;word-break:break-all; border:1px solid black}
<div class=c2>
break-all,是斷開單詞 翻譯社在單詞到鴻溝時,下個字母主動到下一行。首要解決了長串英文 翻譯問題。
<div class=c6>
中英文混排的情況。Chinese and English. 中英文混排的情形 翻譯社Chinese and English.
table {
<br>
</div>
在 IE 下沒有任何問題,在 FF 下,長串英文會被遮住超越的內容。
}
keep-all,是指Chinese, Japanese, and Korean不斷詞。即只用此時,不消word-wrap,中文就不會換行了。(英文語句正常 翻譯社)
中英文混排 翻譯情況。Chinese and English. 中英文混排的情況。Chinese and English.
safjaskflasjfklsajfklasjflksajflksjflkasjfksafj
width:expression(this.width > 600 ? "600px" : this.width);
<div class=c7>
中英文混排 翻譯情況 翻譯社Chinese and English. 中英文混排 翻譯情形。Chinese and English. <td class="NoNewline">不換行不換行不換行不換行不換行不換行不換行不換行不換行不換行</td>本文來自: http://blog.xuite.net/s925517/mylife/85386335-%5BCSS%5D%E5%BC%B7%E5%88%B6HTML%E8%A1%A8%E6%A0%BC%E5%8有關翻譯的問題歡迎諮詢天成翻譯社 |