\documentclass[10pt,a4paper]{article} % Packages \usepackage{fancyhdr} % For header and footer \usepackage{multicol} % Allows multicols in tables \usepackage{tabularx} % Intelligent column widths \usepackage{tabulary} % Used in header and footer \usepackage{hhline} % Border under tables \usepackage{graphicx} % For images \usepackage{xcolor} % For hex colours %\usepackage[utf8x]{inputenc} % For unicode character support \usepackage[T1]{fontenc} % Without this we get weird character replacements \usepackage{colortbl} % For coloured tables \usepackage{setspace} % For line height \usepackage{lastpage} % Needed for total page number \usepackage{seqsplit} % Splits long words. %\usepackage{opensans} % Can't make this work so far. Shame. Would be lovely. \usepackage[normalem]{ulem} % For underlining links % Most of the following are not required for the majority % of cheat sheets but are needed for some symbol support. \usepackage{amsmath} % Symbols \usepackage{MnSymbol} % Symbols \usepackage{wasysym} % Symbols %\usepackage[english,german,french,spanish,italian]{babel} % Languages % Document Info \author{mdsis2049} \pdfinfo{ /Title (computers-data-and-the-web.pdf) /Creator (Cheatography) /Author (mdsis2049) /Subject (Computers, Data, and the Web Cheat Sheet) } % Lengths and widths \addtolength{\textwidth}{6cm} \addtolength{\textheight}{-1cm} \addtolength{\hoffset}{-3cm} \addtolength{\voffset}{-2cm} \setlength{\tabcolsep}{0.2cm} % Space between columns \setlength{\headsep}{-12pt} % Reduce space between header and content \setlength{\headheight}{85pt} % If less, LaTeX automatically increases it \renewcommand{\footrulewidth}{0pt} % Remove footer line \renewcommand{\headrulewidth}{0pt} % Remove header line \renewcommand{\seqinsert}{\ifmmode\allowbreak\else\-\fi} % Hyphens in seqsplit % This two commands together give roughly % the right line height in the tables \renewcommand{\arraystretch}{1.3} \onehalfspacing % Commands \newcommand{\SetRowColor}[1]{\noalign{\gdef\RowColorName{#1}}\rowcolor{\RowColorName}} % Shortcut for row colour \newcommand{\mymulticolumn}[3]{\multicolumn{#1}{>{\columncolor{\RowColorName}}#2}{#3}} % For coloured multi-cols \newcolumntype{x}[1]{>{\raggedright}p{#1}} % New column types for ragged-right paragraph columns \newcommand{\tn}{\tabularnewline} % Required as custom column type in use % Font and Colours \definecolor{HeadBackground}{HTML}{333333} \definecolor{FootBackground}{HTML}{666666} \definecolor{TextColor}{HTML}{333333} \definecolor{DarkBackground}{HTML}{A3A3A3} \definecolor{LightBackground}{HTML}{F3F3F3} \renewcommand{\familydefault}{\sfdefault} \color{TextColor} % Header and Footer \pagestyle{fancy} \fancyhead{} % Set header to blank \fancyfoot{} % Set footer to blank \fancyhead[L]{ \noindent \begin{multicols}{3} \begin{tabulary}{5.8cm}{C} \SetRowColor{DarkBackground} \vspace{-7pt} {\parbox{\dimexpr\textwidth-2\fboxsep\relax}{\noindent \hspace*{-6pt}\includegraphics[width=5.8cm]{/web/www.cheatography.com/public/images/cheatography_logo.pdf}} } \end{tabulary} \columnbreak \begin{tabulary}{11cm}{L} \vspace{-2pt}\large{\bf{\textcolor{DarkBackground}{\textrm{Computers, Data, and the Web Cheat Sheet}}}} \\ \normalsize{by \textcolor{DarkBackground}{mdsis2049} via \textcolor{DarkBackground}{\uline{cheatography.com/193569/cs/40524/}}} \end{tabulary} \end{multicols}} \fancyfoot[L]{ \footnotesize \noindent \begin{multicols}{3} \begin{tabulary}{5.8cm}{LL} \SetRowColor{FootBackground} \mymulticolumn{2}{p{5.377cm}}{\bf\textcolor{white}{Cheatographer}} \\ \vspace{-2pt}mdsis2049 \\ \uline{cheatography.com/mdsis2049} \\ \end{tabulary} \vfill \columnbreak \begin{tabulary}{5.8cm}{L} \SetRowColor{FootBackground} \mymulticolumn{1}{p{5.377cm}}{\bf\textcolor{white}{Cheat Sheet}} \\ \vspace{-2pt}Published 30th September, 2023.\\ Updated 30th November, 2023.\\ Page {\thepage} of \pageref{LastPage}. \end{tabulary} \vfill \columnbreak \begin{tabulary}{5.8cm}{L} \SetRowColor{FootBackground} \mymulticolumn{1}{p{5.377cm}}{\bf\textcolor{white}{Sponsor}} \\ \SetRowColor{white} \vspace{-5pt} %\includegraphics[width=48px,height=48px]{dave.jpeg} Measure your website readability!\\ www.readability-score.com \end{tabulary} \end{multicols}} \begin{document} \raggedright \raggedcolumns % Set font size to small. Switch to any value % from this page to resize cheat sheet text: % www.emerson.emory.edu/services/latex/latex_169.html \footnotesize % Small font. \begin{multicols*}{2} \begin{tabularx}{8.4cm}{x{2.56 cm} x{5.44 cm} } \SetRowColor{DarkBackground} \mymulticolumn{2}{x{8.4cm}}{\bf\textcolor{white}{Precursors to Computers}} \tn % Row 0 \SetRowColor{LightBackground} Precursor & {\bf{Something that comes before}}. In this case: A machine that is not a computer, but does computer-like things. \tn % Row Count 5 (+ 5) % Row 1 \SetRowColor{white} Abacus & {\bf{The first calculating device.}} An ancient tool, made of wood or metal, with movable beads that people use to help to count and do basic math. \tn % Row Count 11 (+ 6) % Row 2 \SetRowColor{LightBackground} Napier's Bones & 17th century calculating device; a box containing bone rods with numbers on them, used to do basic math incl. addition, subtraction, multiplication and division. \tn % Row Count 17 (+ 6) % Row 3 \SetRowColor{white} Pascal's calculator & 17th century calculating device; a box containing gears that displayed numbers; used for addition and subtraction. Modified by Leibniz ({\bf{Leibniz's calculator}}) to do multiplication and division too. \tn % Row Count 25 (+ 8) % Row 4 \SetRowColor{LightBackground} Jacquard loom & A 19th century machine for weaving silk; operators used {\bf{punched cards}} to tell the machine what patterns to weave. \tn % Row Count 30 (+ 5) \end{tabularx} \par\addvspace{1.3em} \vfill \columnbreak \begin{tabularx}{8.4cm}{x{2.56 cm} x{5.44 cm} } \SetRowColor{DarkBackground} \mymulticolumn{2}{x{8.4cm}}{\bf\textcolor{white}{Precursors to Computers (cont)}} \tn % Row 5 \SetRowColor{LightBackground} Analytical engine & {\bf{Considered the first mechanical "computer"}}. Made by Charles Babbage in the 19th century, it calculated using gears and cranks. Ada Lovelace (seen as {\bf{the first programmer}}) used it to calculate coefficients of polynomial equations {\emph{(e.g. x$^{\textrm{2}}$ + 2x + 1)}}. \tn % Row Count 10 (+ 10) \hhline{>{\arrayrulecolor{DarkBackground}}--} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{8.4cm}{x{1.76 cm} x{6.24 cm} } \SetRowColor{DarkBackground} \mymulticolumn{2}{x{8.4cm}}{\bf\textcolor{white}{Generations of Computers}} \tn % Row 0 \SetRowColor{LightBackground} First gen. & 1940-1956. Main technology: {\bf{Vacuum tubes}}. Very large, expensive computers such as {\bf{ENIAC}} and {\bf{UNIVAC}}, which took up entire floors of a building and required large cooling systems. Only governments and large companies owned computers. Could only solve one problem at a time; programs took days or weeks to run. Input was through punched cards, output on printed paper, storage on magnetic drums. \tn % Row Count 14 (+ 14) % Row 1 \SetRowColor{white} Second gen. & 1956-1963. Main technology: {\bf{Transistors}}. Since transistors were smaller, computers became smaller too, as well as faster, cheaper and more energy-efficient. Computers became more common in universities and businesses. Input on punched cards, output on printed paper, storage on magnetic core memory, tape, or disks. \tn % Row Count 25 (+ 11) % Row 2 \SetRowColor{LightBackground} Third gen. & 1964-1971. Main technology: {\bf{Integrated circuits}}. Transistors were made smaller and placed on silicon chips (semiconductors), making them much faster. Computers became easier to use \& more popular; people began to use them in small businesses and at home as a hobby. Input on keyboards, output on monitors/screens, storage on magnetic tape or disks. Operating systems developed, increasing computer's power. \tn % Row Count 39 (+ 14) \end{tabularx} \par\addvspace{1.3em} \vfill \columnbreak \begin{tabularx}{8.4cm}{x{1.76 cm} x{6.24 cm} } \SetRowColor{DarkBackground} \mymulticolumn{2}{x{8.4cm}}{\bf\textcolor{white}{Generations of Computers (cont)}} \tn % Row 3 \SetRowColor{LightBackground} Fourth gen. & 1971-present. Main technology: {\bf{Very large scale integration (VLSI)}} which made integrated circuits more complex and powerful, leading to {\bf{microprocessors}}. Computers could now be very small (phones, portable devices). IBM and Apple made desktop computers and personal computers (PCs). These became extremely popular—anyone could have a computer now! Input on keyboard, mouse, touchscreen; output on monitor; storage on HDD/SSD. Graphical user interfaces (GUIs) and networking became common, and the Internet appeared. \tn % Row Count 17 (+ 17) % Row 4 \SetRowColor{white} Fifth gen. & Present+. Main technology: {\bf{Artificial intelligence}}. Parallel processing (with multiple CPUs) and superconductors increased speed \& efficiency. Voice and face recognition, natural language interfaces, quantum computing and nanotechnology appeared. \tn % Row Count 26 (+ 9) \hhline{>{\arrayrulecolor{DarkBackground}}--} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{8.4cm}{X} \SetRowColor{DarkBackground} \mymulticolumn{1}{x{8.4cm}}{\bf\textcolor{white}{Representing Information}} \tn \SetRowColor{white} \mymulticolumn{1}{x{8.4cm}}{We can {\bf{represent information}} in different ways. Using different languages, we can write the number nine as {\bf{9}}, {\bf{IX}} (Roman), {\bf{۹}} (Arabic/Persian), {\bf{नौ}} (Hindi), {\bf{๙}} (Thai), {\bf{九}} (Chinese/Japanese/...), {\bf{구}} (Korean Hangul), {\bf{𠃩}}, {\bf{𒐎}}, and so on. We can use other codes and visual systems too, like Braille, Morse code, hand signals and semaphore. \newline % Row Count 8 (+ 8) To represent information ({\bf{data}}) in computers, we use a number system called {\bf{binary}} Binary is a {\emph{base-2}} system, which means it uses only {\emph{two}} digits, 0 and 1. This is different from the regular {\emph{base-10}} {\bf{decimal}} (or denary) system, which uses the ten digits from 0 to 9. As well, we sometimes use a {\emph{base-16}} {\bf{hexadecimal}} system, which has {\emph{sixteen}} digits. Hexadecimal digits include the letters A, B, C, D, E, and F to represent the values 10, 11, 12, 13, 14, and 15. We can write the same value in different ways using different number systems. \newline % Row Count 20 (+ 12) Along with these number systems, we can use two kinds of {\bf{character sets}} called {\bf{ASCII}} and {\bf{Unicode}}. These allow us to represent written characters using numbers. For example, the letter A is represented in ASCII by the decimal number 65, the binary number 01000001, and the hexadecimal number 41. The character 万 is represented in Unicode by the decimal number 19975, the binary number 0100111000000111, and the hexadecimal number 4E07. \newline % Row Count 29 (+ 9) ASCII is an 8-bit code. Its great advantage is that it takes up {\bf{very little space}} to store data—only 8 bits (or one {\bf{byte}}) for one character. On the other hand, its disadvantage is that it can only represent {\bf{a total of 255 characters}}. The characters it displays mostly come from Latin languages like English, French, and Spanish. \newline % Row Count 36 (+ 7) } \tn \end{tabularx} \par\addvspace{1.3em} \vfill \columnbreak \begin{tabularx}{8.4cm}{X} \SetRowColor{DarkBackground} \mymulticolumn{1}{x{8.4cm}}{\bf\textcolor{white}{Representing Information (cont)}} \tn \SetRowColor{white} \mymulticolumn{1}{x{8.4cm}}{Unicode has 16-bit and 32-bit varieties. Its great advantage is that it can represent {\bf{characters from many languages}}, including Arabic, Chinese, Japanese, Korean, Russian, Thai, and many others. On the other hand, its disadvantage is that {\bf{each character takes up a lot of space}} to store and send over a network.% Row Count 7 (+ 7) } \tn \hhline{>{\arrayrulecolor{DarkBackground}}-} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{8.4cm}{x{2.356 cm} x{2.508 cm} x{2.736 cm} } \SetRowColor{DarkBackground} \mymulticolumn{3}{x{8.4cm}}{\bf\textcolor{white}{Numbers in Different Systems}} \tn % Row 0 \SetRowColor{LightBackground} \{\{width=33\}\}{\bf{Binary}} (base 2) & \{\{width=33\}\}{\bf{Decimal}} (base 10) & \{\{width=33\}\}{\bf{Hexadecimal}} (base 16) \tn % Row Count 3 (+ 3) % Row 1 \SetRowColor{white} 0000 & 0 & 0 \tn % Row Count 4 (+ 1) % Row 2 \SetRowColor{LightBackground} 0001 & 1 & 1 \tn % Row Count 5 (+ 1) % Row 3 \SetRowColor{white} 0010 & 2 & 2 \tn % Row Count 6 (+ 1) % Row 4 \SetRowColor{LightBackground} 0011 & 3 & 3 \tn % Row Count 7 (+ 1) % Row 5 \SetRowColor{white} 0100 & 4 & 4 \tn % Row Count 8 (+ 1) % Row 6 \SetRowColor{LightBackground} 0101 & 5 & 5 \tn % Row Count 9 (+ 1) % Row 7 \SetRowColor{white} 0110 & 6 & 6 \tn % Row Count 10 (+ 1) % Row 8 \SetRowColor{LightBackground} 0111 & 7 & 7 \tn % Row Count 11 (+ 1) % Row 9 \SetRowColor{white} 1000 & 8 & 8 \tn % Row Count 12 (+ 1) % Row 10 \SetRowColor{LightBackground} 1001 & 9 & 9 \tn % Row Count 13 (+ 1) % Row 11 \SetRowColor{white} 1010 & 10 & A \tn % Row Count 14 (+ 1) % Row 12 \SetRowColor{LightBackground} 1011 & 11 & B \tn % Row Count 15 (+ 1) % Row 13 \SetRowColor{white} 1100 & 12 & C \tn % Row Count 16 (+ 1) % Row 14 \SetRowColor{LightBackground} 1101 & 13 & D \tn % Row Count 17 (+ 1) % Row 15 \SetRowColor{white} 1110 & 14 & E \tn % Row Count 18 (+ 1) % Row 16 \SetRowColor{LightBackground} 1111 & 15 & F \tn % Row Count 19 (+ 1) \hhline{>{\arrayrulecolor{DarkBackground}}---} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{8.4cm}{X} \SetRowColor{DarkBackground} \mymulticolumn{1}{x{8.4cm}}{\bf\textcolor{white}{The Digital World}} \tn \SetRowColor{white} \mymulticolumn{1}{x{8.4cm}}{What does it mean that {\bf{information is digital}}? It means that all the information we have can be represented as data on computers, using the {\emph{bi}}nary digi{\emph{ts}} ({\bf{bits}}) {\bf{0}} and {\bf{1}}. Any computer can use this data, display it, or send it to someone else. That means you can {\bf{store}} everything you know on a computer, and you can {\bf{share}} it with anyone else who uses a computer. Using the Internet and the Web, you can share many types of {\bf{media}} like words, pictures, video or music clips. {\emph{A digital world is a world where it's easy to connect!}} \newline % Row Count 12 (+ 12) One of the ways we can display and share information is using a {\bf{website}}. If you know how to use tools like {\bf{HTML}} and {\bf{CSS}}, it is easy to create your own website to share with the world.% Row Count 16 (+ 4) } \tn \hhline{>{\arrayrulecolor{DarkBackground}}-} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{8.4cm}{x{2.16 cm} x{5.84 cm} } \SetRowColor{DarkBackground} \mymulticolumn{2}{x{8.4cm}}{\bf\textcolor{white}{Building Blocks of the Web}} \tn % Row 0 \SetRowColor{LightBackground} HTML & {\bf{Hypertext Markup Language}}. Called the "building blocks of the Web" because we use it to give structure to a web page. \tn % Row Count 5 (+ 5) % Row 1 \SetRowColor{white} HTML tag & A code that {\bf{explains what something is}} on a web page. HTML tags are always surrounded by angle brackets (as in \textless{}b\textgreater{}). Most tags must be paired with a matching end tag; between these is the text or object that the tag applies to. For example, \textless{}b\textgreater{}{\bf{hello}}\textless{}/b\textgreater{} says that 'hello' is bold text. \tn % Row Count 16 (+ 11) % Row 2 \SetRowColor{LightBackground} HTML attribute & \{\{noshy\}\}An {\bf{extra piece of information}} about an HTML tag. For example, in the tag \textless{}p align="right"\textgreater{}, the 'align' attribute says that the paragraph should be aligned to the right. The part between the quotes ("") is called the attribute's {\bf{value}}. \tn % Row Count 25 (+ 9) % Row 3 \SetRowColor{white} CSS & {\bf{Cascading Style Sheets}}. Where HTML acts like building blocks giving structure, CSS acts like paint and decorations giving a web page a beautiful appearance. CSS can be {\emph{inline}} in an HTML document, or it can exist in its own file (a {\emph{stylesheet}}). \tn % Row Count 34 (+ 9) \end{tabularx} \par\addvspace{1.3em} \vfill \columnbreak \begin{tabularx}{8.4cm}{x{2.16 cm} x{5.84 cm} } \SetRowColor{DarkBackground} \mymulticolumn{2}{x{8.4cm}}{\bf\textcolor{white}{Building Blocks of the Web (cont)}} \tn % Row 4 \SetRowColor{LightBackground} Inline CSS & \{\{noshy\}\}A style that can be added {\bf{directly to an HTML tag}} to change its appearance. For example, in the tag \textless{}span style="color:red"\textgreater{}, the 'style' attribute says that the text enclosed by the span tag must be coloured red. \tn % Row Count 8 (+ 8) % Row 5 \SetRowColor{white} \seqsplit{Stylesheet} & A separate {\bf{file}} (with extension .css) {\bf{that contains CSS rules}}. Writing CSS in a stylesheet makes it easier to update the appearance of large HTML files, because making one change to a rule will update many HTML tags. \tn % Row Count 16 (+ 8) % Row 6 \SetRowColor{LightBackground} CSS rule & \{\{noshy\}\}A {\bf{set of CSS styles}} that apply to one or more objects. For example, the rule h1~\{~color:blue~\} will make the \textless{}h1\textgreater{} tag blue. \tn % Row Count 22 (+ 6) % Row 7 \SetRowColor{white} CSS \seqsplit{declaration} & \{\{noshy\}\}A {\bf{single style}} in a CSS rule. For example, in the rule h1~\{~color:\#9c9; font-size:120\%~\}, 'color:\#9c9' and 'font-size:120\%' are both declarations. If there is more than one declaration in a rule, they must be separated by a semicolon (;). \tn % Row Count 32 (+ 10) \end{tabularx} \par\addvspace{1.3em} \vfill \columnbreak \begin{tabularx}{8.4cm}{x{2.16 cm} x{5.84 cm} } \SetRowColor{DarkBackground} \mymulticolumn{2}{x{8.4cm}}{\bf\textcolor{white}{Building Blocks of the Web (cont)}} \tn % Row 8 \SetRowColor{LightBackground} CSS selector & \{\{noshy\}\}The {\bf{object}} that a CSS rule applies to. For example, in the rule h1~\{~text-decoration:underline~\}, the selector is 'h1'. \tn % Row Count 6 (+ 6) % Row 9 \SetRowColor{white} CSS class & \{\{noshy\}\}A kind of CSS selector that applies to HTML tags with the matching 'class' attribute. A selector that starts with a dot (.) represents a CSS class. For example, the rule .purp~\{~color:purple~\} will match the HTML tag \textless{}p class="purp"\textgreater{}. \tn % Row Count 15 (+ 9) % Row 10 \SetRowColor{LightBackground} CSS property & \{\{noshy\}\}The {\bf{kind of formatting}} a declaration changes. For example, in the rule h1~\{~font-size:120\%~\}, the property is 'font-size'. The part after the colon (:) is the property's {\bf{value}}. \tn % Row Count 23 (+ 8) \hhline{>{\arrayrulecolor{DarkBackground}}--} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{8.4cm}{x{2.232 cm} x{1.8 cm} x{1.368 cm} x{1.8 cm} } \SetRowColor{DarkBackground} \mymulticolumn{4}{x{8.4cm}}{\bf\textcolor{white}{Common HTML Formatting Tags}} \tn % Row 0 \SetRowColor{LightBackground} \{\{width=15\}\}\{\{noshy\}\}\textless{}b\textgreater{}, \textless{}strong\textgreater{} & \{\{width=35\}\}Bold text. & \{\{width=15\}\}\textless{}i\textgreater{}, \textless{}em\textgreater{} & \{\{width=35\}\}Italic text. \tn % Row Count 3 (+ 3) % Row 1 \SetRowColor{white} \textless{}u\textgreater{} & \seqsplit{Underlined} text. & \textless{}li\textgreater{} & List item. \tn % Row Count 5 (+ 2) % Row 2 \SetRowColor{LightBackground} \textless{}ul\textgreater{} & Unordered list \seqsplit{(bullets).} & \textless{}ol\textgreater{} & Ordered list \seqsplit{(numbers).} \tn % Row Count 8 (+ 3) % Row 3 \SetRowColor{white} \textless{}h1\textgreater{} & Heading, level 1. & \textless{}h2\textgreater{} & Heading, level 2. \tn % Row Count 10 (+ 2) % Row 4 \SetRowColor{LightBackground} \textless{}h{[}3-6{]}\textgreater{} & Heading, levels 3–6. & \textless{}sub\textgreater{} & Subscript (as in H{\bf{₂}}O). \tn % Row Count 13 (+ 3) % Row 5 \SetRowColor{white} \textless{}sup\textgreater{} & \seqsplit{Superscript} (as in x{\bf{$^{\textrm{2}}$}}). & \textless{}code\textgreater{} & Code snippet \seqsplit{(`monospaced`)}. \tn % Row Count 16 (+ 3) \hhline{>{\arrayrulecolor{DarkBackground}}----} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{8.4cm}{x{1.44 cm} x{2.304 cm} x{1.08 cm} x{2.376 cm} } \SetRowColor{DarkBackground} \mymulticolumn{4}{x{8.4cm}}{\bf\textcolor{white}{Other Common HTML tags}} \tn % Row 0 \SetRowColor{LightBackground} \{\{width=15\}\}\{\{noshy\}\}\textless{}p\textgreater{} & \{\{width=35\}\}Paragraph. & \{\{width=15\}\}\textless{}span\textgreater{} & \{\{width=35\}\}Span of inline text (e.g. a few words inside a paragraph) \tn % Row Count 6 (+ 6) % Row 1 \SetRowColor{white} \textless{}div\textgreater{} & Division, or section, of text. & \textless{}img \seqsplit{src="..."} /\textgreater{} & Image. The 'src' tag is the URL of the image to be shown. \tn % Row Count 11 (+ 5) % Row 2 \SetRowColor{LightBackground} \textless{}a \seqsplit{href="..}."\textgreater{} & Hyperlink. The 'href' attribute is the URL of the page where you will go when clicking the link. & \textless{}br /\textgreater{} & Line break. \tn % Row Count 19 (+ 8) \hhline{>{\arrayrulecolor{DarkBackground}}----} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{8.4cm}{p{1.04 cm} x{6.96 cm} } \SetRowColor{DarkBackground} \mymulticolumn{2}{x{8.4cm}}{\bf\textcolor{white}{Common HTML Attributes}} \tn % Row 0 \SetRowColor{LightBackground} align & Alignment of an object. ex: {\emph{left, right}}. \tn % Row Count 2 (+ 2) % Row 1 \SetRowColor{white} style & Inline CSS that applies to an object. ex: {\emph{color:red}}. \tn % Row Count 4 (+ 2) % Row 2 \SetRowColor{LightBackground} class & CSS class name that applies to an object. ex: {\emph{highlight, red-text, student-name}}. \tn % Row Count 7 (+ 3) % Row 3 \SetRowColor{white} \seqsplit{height} & How tall an object is. ex: {\emph{256px, 2em, 100\%}}. \tn % Row Count 9 (+ 2) % Row 4 \SetRowColor{LightBackground} width & How wide an object is. ex: {\emph{150px, 2em, 75\%}}. \tn % Row Count 11 (+ 2) \hhline{>{\arrayrulecolor{DarkBackground}}--} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{8.4cm}{x{2.08 cm} x{5.92 cm} } \SetRowColor{DarkBackground} \mymulticolumn{2}{x{8.4cm}}{\bf\textcolor{white}{Common CSS Formatting Properties}} \tn % Row 0 \SetRowColor{LightBackground} color & Colour of text. ex: {\emph{red, \#000, \#ff0000.}} \tn % Row Count 2 (+ 2) % Row 1 \SetRowColor{white} \seqsplit{background} & Background or highlight. ex: {\emph{yellow, \#0e0, \#cccc99.}} \tn % Row Count 4 (+ 2) % Row 2 \SetRowColor{LightBackground} font-size & Size of text. ex: {\emph{16pt, 12px, 1em, 120\%.}} \tn % Row Count 6 (+ 2) % Row 3 \SetRowColor{white} \seqsplit{font-weight} & How bold the text is. ex: {\emph{bold, normal.}} \tn % Row Count 8 (+ 2) % Row 4 \SetRowColor{LightBackground} \seqsplit{font-style} & Style of the text. ex: {\emph{italic.}} \tn % Row Count 10 (+ 2) % Row 5 \SetRowColor{white} \seqsplit{font-family} & Name or type of font used. ex: {\emph{Helvetica, Arial, serif.}} \tn % Row Count 12 (+ 2) % Row 6 \SetRowColor{LightBackground} \seqsplit{line-height} & Space between lines. ex: {\emph{24pt, 36px, 2em, 140\%.}} \tn % Row Count 14 (+ 2) % Row 7 \SetRowColor{white} \seqsplit{text-align} & Alignment of text in an object. ex: left, right, center. \tn % Row Count 16 (+ 2) % Row 8 \SetRowColor{LightBackground} \seqsplit{text-transform} & Case of text. ex: {\emph{lowercase, uppercase, capitalized.}} \tn % Row Count 18 (+ 2) \hhline{>{\arrayrulecolor{DarkBackground}}--} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{8.4cm}{x{1.2 cm} x{6.8 cm} } \SetRowColor{DarkBackground} \mymulticolumn{2}{x{8.4cm}}{\bf\textcolor{white}{Common CSS Layout Properties}} \tn % Row 0 \SetRowColor{LightBackground} \seqsplit{border} & Border around an object. ex: {\emph{4px solid blue, 1px dotted \#ffddff}}. \tn % Row Count 2 (+ 2) % Row 1 \SetRowColor{white} \seqsplit{padding} & Blank space {\emph{inside}} the object's border. ex: {\emph{4px, .5em}}.\{\{nl\}\}Multiple values can be added for top, right, bottom, left padding. ex: {\emph{2px 0px 4px 0px}}. \tn % Row Count 7 (+ 5) % Row 2 \SetRowColor{LightBackground} \seqsplit{margin} & Blank space {\emph{outside}} the object's border. ex: {\emph{4px, .5em}}.\{\{nl\}\}Multiple values can be added for top, right, bottom, left margin. ex: {\emph{2px 0px 4px 0px}}. \tn % Row Count 12 (+ 5) % Row 3 \SetRowColor{white} \seqsplit{height} & How tall an object is. ex: {\emph{256px, 2em, 100\%}}. \tn % Row Count 14 (+ 2) % Row 4 \SetRowColor{LightBackground} width & How wide an object is. ex: {\emph{150px, 2em, 75\%}}. \tn % Row Count 16 (+ 2) \hhline{>{\arrayrulecolor{DarkBackground}}--} \end{tabularx} \par\addvspace{1.3em} % That's all folks \end{multicols*} \end{document}