Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

CSS text-border? [duplicate]

Tags:

css

Possible Duplicate:
CSS Font Border?

Is it possible to set a 'text-border' with CSS?

Best would be to have multiple borders? something like on the image

enter image description here

like image 704
Tomas Jancik Avatar asked Jan 27 '13 22:01

Tomas Jancik


People also ask

How do you avoid double border in CSS?

Add a border-left and border-top to the parent. Add border-right and border-bottom to each of the children.

How do you put a border on text in CSS?

Use the -webkit-text-stroke Property to Apply Borders to Font in CSS. We can use the text-stroke property on a text to apply borders to a font in CSS. We need to use the webkit prefix ahead of the text-stroke property to use the feature. However, it only works on the web-kit based browsers like Safari and Chrome.


2 Answers

Well you could try a font shadow. Something with multiple borders might have to be done with an image though.

           text-shadow: -1px 0 black, 0 1px black, 1px 0 black, 0 -1px black;
like image 79
AgnosticDev Avatar answered Sep 21 '22 19:09

AgnosticDev


I think you may want to take a look at CSS text-shadow

http://www.quirksmode.org/css/textshadow.html

You cannot achieve multiple borders but you can do some amazing things with it:

http://line25.com/articles/using-css-text-shadow-to-create-cool-text-effects

(i love that neon effect :)

like image 38
Andrea Ligios Avatar answered Sep 24 '22 19:09

Andrea Ligios