calc() lets you do a simple calculation, for
CSS property values.
It can be used anywhere for a length or number.
width: calc(100% - 80px);
you can use any of the following operators:
+→ add. (must have space before and after)
-→ subtract. (must have space before and after)
*→ times. One of the argument must be a number.
/→ divide. The right-hand side must be a number.
Parentheses can be used for grouping.
- Layout Tutorial
- Display Property
- Position: static, relative, fixed, absolute
- Pure CSS Table
- Tabbed Menu
- 3 Columns Page Layout
- Multi-Column Layout for Text Flow
- Fix Element to Window
- Flowing List
- Text Over Image
- Text Flow Around Image
- OverFlow, Scrollbar
Line Wrap, Justification
- Line Wrap
- Text Alignment, Justification
- Match first-letter and first-line
- “:before”, “:after”
- Text Decoration: Underline, Overline, Line-Through
- Letter Spacing, Word Spacing
- Computed Style
- Pseudo Class vs Pseudo Element
- Media Query
- Data URI Scheme
- protocol-relative URL
- Default Unit
- Declaring Character Set in CSS File
- Jargons Explained: Tag, Element, Node, Object, Attribute, Property, Method
- Display Table on Small Screen
- Fixed Aspect Ratio
- Add Icon to Links
- Progress Bar Example
If you have a question, put $5 at patreon and message me.