Saturday, 19 March 2016

unicode - What characters can be used for up/down triangle (arrow without stem) for display in HTML?




I'm looking for a HTML or ASCII character which is a triangle pointing up or down so that I can use it as a toggle switch.



I found ↑ (), and ↓ () - but those have a narrow stem. I'm looking just for the HTML arrow "head".


Answer



Unicode arrows heads:




  • ▲ - U+25B2 BLACK UP-POINTING TRIANGLE

  • ▼ - U+25BC BLACK DOWN-POINTING TRIANGLE

  • ▴ - U+25B4 SMALL BLACK UP-POINTING TRIANGLE


  • ▾ - U+25BE SMALL BLACK DOWN-POINTING TRIANGLE



For ▲ and ▼ use and respectively if you cannot include Unicode characters directly (use UTF-8!).



Note that the font support for the smaller versions is not as good. Better to use the large versions in smaller font.



More Unicode arrows are at:






Lastly, these arrows are not ASCII, including ↑ and ↓: they are Unicode.


No comments:

Post a Comment

c++ - Does curly brackets matter for empty constructor?

Those brackets declare an empty, inline constructor. In that case, with them, the constructor does exist, it merely does nothing more than t...