Questions tagged [word-spacing]

a CSS property that increases or decreases the white space between words.

Word spacing in typography refers to the size of the space between words. It should be distinguished from letter spacing (the spacing between the letters within each word) and sentence spacing (the spacing between sentences).

Word-spacing is an attribute in CSS and can never be negative.

32 questions
4
votes
2 answers

underline a paragraph having word-spacing set

When using word-spacing in an underlined element, if the element contains spans, spaces are not correctly underlined making it really ugly... Is there a work around for that? p { text-decoration: underline; word-spacing: 1em; }

Sharcoux
  • 5,546
  • 7
  • 45
  • 78
4
votes
5 answers

split String by space separated

I need to split words by space separated in java, so I have used .split function in-order to achieve that like as shown below String keyword = "apple mango "; String keywords [] = keyword .split(" "); The above code is working fine but the only is…
Alex Man
  • 4,746
  • 17
  • 93
  • 178
3
votes
5 answers

Adjust spaces between text or words in html

I have a problem is how adjust spaces between text or words in html. I want my result 2 "colon" alignment can adjust same line. Below is my sample code: Name :
Date…
David Holly
  • 373
  • 1
  • 9
3
votes
3 answers

Get word-spacing width in pixels

I'm stuck on how to find the width in pixels of one space between words. For example, if I have a sentence: "The quick brown fox jumps over the lazy dog." and I want the width in pixels of the whitespaces (which will all be the same), is there a…
lnamba
  • 1,681
  • 3
  • 18
  • 26
3
votes
1 answer

CSS: Line break after first word for any content

I need to leave only one word on the first line regardless of content, so no additional markup possible. I've tried to do this using word-spacing with ::first-line pseudo-element. This works fine in Firefox or IE, but fails in WebKit browsers…
Dmitry Yantsen
  • 1,145
  • 11
  • 24
3
votes
1 answer

Auto space a text each 4 characters by CSS?

I wanted to ask if that text can automatically change to that form when you type by CSS. Before : 513031421694 // After : 5130 3142 1694 I tried these ones (letter-spacing / word-spacing), without success, and I can only touch the CSS.
GoldMath
  • 79
  • 1
  • 2
  • 5
3
votes
1 answer

UIWebView Rendering differences in iOS 6 and iOS 7

I have an application which uses a lot of HTML to display content within each "page" of content. Suddenly, just by running on iOS 7, the HTML has started displaying incorrectly. All of the interword spacing is enlarged, causing the text to…
borrrden
  • 33,256
  • 8
  • 74
  • 109
2
votes
0 answers

text-align:center + word-spacing not working in Safari

I have two elements of words which should be on the same line and separated by char/image ONLY when they are on the same line. The text must be centered. My current solution works on all browsers but Safari, because Safari does't correctly center…
NthDegree
  • 1,301
  • 2
  • 15
  • 29
2
votes
1 answer

Justify paragraphs by changing the word-spacing

Is there a smart way to justify paragraphs inside a fixed-width div tag without wrapping and only changing the word-spacing? See link below. Cheers https://jsfiddle.net/TheCoder/zhL895x9/embedded/result/