Make WordPress Core

Opened 15 years ago

Closed 15 years ago

#8161 closed enhancement (fixed)

Spaced hyphens into spaced dashes

Reported by: joshuagoodwin's profile joshuagoodwin Owned by: joshuagoodwin's profile joshuagoodwin
Milestone: 2.8 Priority: normal
Severity: normal Version: 2.7
Component: General Keywords: has-patch tested
Focuses: Cc:

Description

We all know that "---" and " -- " are changed into em-dashes (—), and that "--" is changed into an en-dash (—). But another bit of formatting really ought to take place - space-surrounded hyphens, like that one, ought to be turned into en-dashes by wp-includes/formatting.php. This is what Microsoft Word does, and - says Wikipedia - the style is adopted by many publishers. So this easy-to-implement feature really ought to be implemented - it happens with the likes of Textpattern.

Attachments (2)

formatting.php (68.5 KB) - added by joshuagoodwin 15 years ago.
Yes, yes, it's not in a .diff format. My sincere, sincere apologies for this. Changes in lines 47 & 48.
8161.diff (1.3 KB) - added by ionfish 15 years ago.

Download all attachments as: .zip

Change History (7)

#1 @joshuagoodwin
15 years ago

  • Owner joshuagoodwin deleted

@joshuagoodwin
15 years ago

Yes, yes, it's not in a .diff format. My sincere, sincere apologies for this. Changes in lines 47 & 48.

@ionfish
15 years ago

#2 @ionfish
15 years ago

  • Keywords has-patch added
  • Milestone set to 2.8
  • Version set to 2.7

There you go.

#3 @joshuagoodwin
15 years ago

  • Owner set to joshuagoodwin
  • Priority changed from low to normal
  • Severity changed from trivial to normal

#4 @Denis-de-Bernardy
15 years ago

  • Keywords tested added; formatting.php removed

#5 @automattor
15 years ago

  • Resolution set to fixed
  • Status changed from new to closed

(In [10973]) Spaced hyphens into spaced dashes, props ionfish, fixes #8161

Note: See TracTickets for help on using tickets.