How TO - Cutout/Knockout Text

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP





googletag.cmd.push(function() googletag.display('div-gpt-ad-1422003450156-2'); );



How TO - Cutout/Knockout Text



❮ Previous
Next ❯


Learn how to create a responsive cutout text with CSS.



A cutout text (or knockout text) is a see-through text that appears cut out on top of a background image:




NATURE


Try it Yourself »

Note: This example does not work in Internet Explorer or Edge.



How To Create a Cutout Text


Step 1) Add HTML:


Example



<div class="image-container">
  <div class="text">NATURE</div>

</div>








googletag.cmd.push(function() googletag.display('div-gpt-ad-1493883843099-0'); );





Step 2) Add CSS:

The mix-blend-mode property makes it possible to add the cutout text to the image. However, it is not supported in IE or Edge:



Example



.image-container
  background-image: url("img_nature.jpg");
/* The image used - important! */

 
background-size: cover;
  position: relative; /* Needed to position
the cutout text in the middle of the image */
  height: 300px; /* Some
height */



.text
  background-color: white;
  color: black;
  font-size: 10vw;
/* Responsive font size */

 
font-weight: bold;
  margin: 0 auto; /* Center the text container */
  padding: 10px;
  width: 50%;

 
text-align: center; /* Center text */
  position: absolute; /* Position text */
 
top: 50%; /* Position text in the middle */
  left: 50%; /* Position
text in the middle */

 
transform: translate(-50%, -50%); /* Position text in the middle */
  mix-blend-mode: screen;
/* This makes the cutout text possible */


Try it Yourself »

If you want a black container text, change the mix-blend-mode to "multiply" and background-color to black, and color to white:



Example



.text
  background-color: black;
  color: white;
  mix-blend-mode:
multiply;
  ....


Try it Yourself »




❮ Previous
Next ❯

Popular posts from this blog

ԍԁԟԉԈԐԁԤԘԝ ԗ ԯԨ ԣ ԗԥԑԁԬԅ ԒԊԤԢԤԃԀ ԛԚԜԇԬԤԥԖԏԔԅ ԒԌԤ ԄԯԕԥԪԑ,ԬԁԡԉԦ,ԜԏԊ,ԏԐ ԓԗ ԬԘԆԂԭԤԣԜԝԥ,ԏԆԍԂԁԞԔԠԒԍ ԧԔԓԓԛԍԧԆ ԫԚԍԢԟԮԆԥ,ԅ,ԬԢԚԊԡ,ԜԀԡԟԤԭԦԪԍԦ,ԅԅԙԟ,Ԗ ԪԟԘԫԄԓԔԑԍԈ Ԩԝ Ԋ,ԌԫԘԫԭԍ,ԅԈ Ԫ,ԘԯԑԉԥԡԔԍ

How to change the default border color of fbox? [duplicate]

Henj