3

Background

I am working a lot at the moment with webfonts, and specifically icon fonts. I need to ascertain the which character a specific icon is for testing purposes, so I can simply type the character &/or copy-paste it.

Example

The CSS of most icon fonts is similar, using the :before pseudo approach e.g.

.icon-search:before{content:"\f002"}

Question

  • I believe this encoding to be called CSS character (Hex) is this the correct?
  • Are there any tools that allow me to enter the escaped CSS character value and convert it to a value I can copy and paste
  • Is there a tool that can convert this to a HTML decimal value e.g. & = simple amperstand

Summary

I would love to be able to find out which character it is so I can simply type it on my keyboard. I have spent ages looking it up but am not quite sure what this type of encoding and conversion is called so can't find what i'm looking for. I'd appreciate some pointers.

Timidfriendly
  • 3,224
  • 4
  • 27
  • 36
  • 1
    If you want to convert the css character "\f002" to a HTML entity then use the following wrap: [hex_value]; So the most simple html conversion is:  – Sjoerd Linders Nov 23 '18 at 13:48

1 Answers1

5

SOLVED - the answer below for completeness

After some research myself I just want to confirm that the encoding used in CSS is indeed called HEX encoding. I did find a converter that allows me to enter the HEX value and converts it to Decimal http://www.binaryhexconverter.com/hex-to-decimal-converter

If you want to use a HTML entity then all you need to do is wrap the converted decimal value in the obligatory &# ; entity start/finish characters and you are good to go.

Example

(HEXvalue = \f002) converts to (Decimal = 61442)

This HTML entity is therefore 

Timidfriendly
  • 3,224
  • 4
  • 27
  • 36