我在具有格式和固定宽度的段落内的文本对齐“对齐”有问题,因为我希望 HTML 中的段落文本看起来完全对齐(就像它会发生在 MS Word 文件中)。但是,这不会发生。我需要修改什么来实现它?
<pre style="color: #000000; font-family: Arial, Helvetica, sans-serif; font-size: medium; width: 500px; text-align: justify;">
I have a problem with the text-align "justify" inside a paragraph with format and fixed width, because I want the paragraph text in HTML to appear totally justified (like it would happen with a MS Word file). However, this does not happen. What I need to modify to achieve it?
</pre>
编辑:如果我用<pre>
标签替换<p>
标签,我的代码可以正常工作。有人可以解释一下为什么吗?也许我使用了错误的<pre>
标签。