Make WordPress Core

Opened 9 years ago

Closed 9 years ago

Last modified 7 years ago

#33279 closed defect (bug) (wontfix)

Smilies forcibly have font-height

Reported by: acbaile's profile acbaile Owned by:
Milestone: Priority: normal
Severity: normal Version: 4.2
Component: Formatting Keywords: has-patch
Focuses: ui Cc:

Description

Hi. I use custom smilies. They usually have size ~ 24x24. With full-size inline-displaing. In versions of Wordpress up to 4.1.6 everything was OK. But starting from 4.2 Wordpress forcibly makes height of smilies in a height of a font. Smilies became very small and lose expression. It's bad. I want to use full-size even if their height is more then font-height.

I tried to look for it in a code, but it's difficult to find reason. I found only that in a code of smile substitution new version of Wordpress hardly adds style="height:1em;" in html-code. I tried to remove it, but not successfull. Smilies stay small. Maybe changes in css-styling affects it?

I think, it's bug, because it reduce functionality. This have to be more flexible, like in previos versions. I rollback my Wordpress to 4.1.6 and I don't want to use newer versions because of this reason.

Attachments (1)

formatting.php.patch (1.8 KB) - added by acbaile 9 years ago.
Removing hard-slyling of height and max-height in html-code for smilies

Download all attachments as: .zip

Change History (8)

@acbaile
9 years ago

Removing hard-slyling of height and max-height in html-code for smilies

#1 @acbaile
9 years ago

Hi! I found solving of my problem. This behaviour was changed by pento in revisions [31733], [31864], [31909]. I consider that hard-styling of height and max-height in html-code is not correct because restricts possibilities of other users (me, for example) to use full-size smilies. He has to look for another solving of his problem.

I made patch, that removes this hard-styling from code.

Last edited 9 years ago by SergeyBiryukov (previous) (diff)

#2 @acbaile
9 years ago

  • Keywords has-patch added

#3 @westonruter
9 years ago

  • Component changed from Customize to General

#4 @SergeyBiryukov
9 years ago

  • Component changed from General to Formatting

#5 @swissspidy
9 years ago

@pento Would you mind having a quick look at this?

#6 follow-up: @pento
9 years ago

  • Milestone Awaiting Review deleted
  • Resolution set to wontfix
  • Status changed from new to closed

This change was on purpose, to ensure that smilies and emoji are displayed correctly in environments that don't load CSS - for example, RSS readers and email. It's not possible to remove these rules without breaking smiley display for every WordPress site.

To override this for your specific use case, the best method would probably be to add a filter to the_content, and preg_replace() the inline style attributes.

#7 in reply to: ↑ 6 @acbaile
7 years ago

Replying to pento:

To override this for your specific use case, the best method would probably be to add a filter to the_content, and preg_replace() the inline style attributes.

You can not not-to-know that this filter affects only content of article from database, not discussed formatting that are hard-styled in php file. Liar!

Note: See TracTickets for help on using tickets.