summaryrefslogtreecommitdiff
path: root/macros/latex/contrib/tiscreen/doc/tiscreen-doc.tex
blob: b1e689ba7428a40e6f4f2e13df0593d42a664c9f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
% TODO: make funciton for printing \LCDcmd

\documentclass[a4paper,12pt]{article}
\usepackage[iso,english]{isodate}
\usepackage[margin=1in]{geometry}
\usepackage[english]{babel}
\usepackage{parskip}
\usepackage[color]{tiscreen}
\usepackage{multicol}
\usepackage{hyperref}
\usepackage{array}
\usepackage{fancyvrb-ex}
\fvset{
	frame=single,
	label=\fbox{Source},
	framesep=4mm,
	numbers=left,
	fontsize=\footnotesize,
}

\newcommand{\LCDsymb}[1]{\large \textLCD{1}|{#1}~|}
\newcommand{\printcmd}[1]{\texttt{\textbackslash #1}}

\title{TI calculator screen (and buttons)\\{\small TI-82 STATS}}
\author{Mustafa Ibrahim}

\begin{document}

\maketitle

\begin{center}
\tiscreen
|10^6*(4^7+1){rarrow}X  |
|       1.6385E10|
|{sqrt}(X)*X/10!      |
|     577971782.1|
|cos{ar}(cos(Ans))  |
|        62.11246|
|{fcur}               |
|                |

\tibtnmatrixextra
\end{center}

\tableofcontents\newpage

\section{Quickstart}

\begin{SideBySideExample}[xrightmargin=5.5cm]
%\usepackage[color]{tiscreen}

\tiscreen
|4+1             |
|               5|
|Ans{sq}         |
|              25|
|{fcur}          |
|                |
|                |
|                |

\tibtnmatrixextra

Lorem
\tibtn[white]{tibtngray}{MATH}
ipsum

\tibtnextra{\tibtn[white]{tibtngray}{MATH}}{TEST}{A}
\end{SideBySideExample}

\section{Package option(s)}
\subsection{Color}

Using the \texttt{color} option will change the colors used by the
\printcmd{LCD} command for printing the screen using \printcmd{tiscreen}. The
colors are defined as \texttt{tiscreenfg} (foreground, i.e. font color) and
\texttt{tiscreenbg} (background) and redefined like this:

\begin{Verbatim}
% Add this to your preamble
\definecolor{tiscreenbg}{HTML}{5d9345}
\definecolor{tiscreenfg}{HTML}{FFFFFF}
\end{Verbatim}

\part{Screen}
\section{LCD size}

The default LCD size is $8 \times 16$ (the size of the TI-82 STATS). It can be
changed by redefining the variables used to determine the size of the display
or by using the original \printcmd{LCD} command.

\begin{Verbatim}
% First method (For entire document)
\def\tiscreenX{16}
\def\tiscreenY{8}

% Second method (Only once)
\LCD{5}{11}
|ANOTHER  |
|EXAMPLE  |
|WITH A   |
|DIFFERENT|
|SIZE     |
\end{Verbatim}

\section{Additional defined characters} \LCDcolors{black}{white}
\begin{center}
	\begin{tabular}{|l|l|>{\ttfamily}l|}
		\multicolumn{3}{c}{\textbf{Added characters}} \\
		\hline
		Name       & Symbol          &\textnormal{\printcmd{LCD} Code} \\
		\hline
		E          & \LCDsymb{sciE}  & \{sciE\} \\
		$\sigma$   & \LCDsymb{sigma} & \{sigma\} \\
		$x^2$      & \LCDsymb{sq}    & \{sq\} \\
		$x^{-1}$   & \LCDsymb{ar}    & \{ar\} \\
		$y^x$      & \LCDsymb{cx}    & \{cx\} \\
		$x_1$      & \LCDsymb{sub1}  & \{sub1\} \\
		$x_2$      & \LCDsymb{sub2}  & \{sub2\} \\
		$x_3$      & \LCDsymb{sub3}  & \{sub3\} \\
		$x_4$      & \LCDsymb{sub4}  & \{sub4\} \\
		$x_5$      & \LCDsymb{sub5}  & \{sub5\} \\
		$x_6$      & \LCDsymb{sub6}  & \{sub6\} \\
		$\bar x$   & \LCDsymb{barx}  & \{barx\} \\
		$\bar y$   & \LCDsymb{bary}  & \{bary\} \\
		\hline
		\multicolumn{3}{c}{\textbf{Redefined characters}} \\
		\hline
		!          & \LCDsymb{!}     & \{!\} \\
		\{         & \LCDsymb{lb}    & \{lb\} \\
		\}         & \LCDsymb{rb}    & \{rb\} \\
		$[$        & \LCDsymb{rb}    & \{rb\} \\
		$]$        & \LCDsymb{rb}    & \{rb\} \\
		$\sqrt{x}$ & \LCDsymb{sqrt}  & \{sqrt\} \\
		e          & \LCDsymb{e}     & e \\
		i          & \LCDsymb{i}     & i \\
		v          & \LCDsymb{v}     & v \\
		w          & \LCDsymb{w}     & w \\
		\hline
	\end{tabular}
\end{center}

\part{Buttons}
\section{Usage}

Use the \printcmd{tibtn} command only prints the button and is usefull when
needing the buttons to be displayed inline. The \printcmd{tibtnextra} takes
extra arguments to show extra options for the button (accesed by the
\tibtnsecond{} and \tibtnalpha{} buttons).

\begin{SideBySideExample}[xrightmargin=5.5cm]
\tibtnextra{\tibtn[white]{tibtngray}{MATH}}{TEST}{A}

Lorem
\tibtn[white]{tibtngray}{MATH}
ipsum
\end{SideBySideExample}

\section{Defined buttons}

\begin{center}
	\begin{tabular}{|>{\ttfamily}l|l|}
		\multicolumn{2}{c}{\textbf{Defined buttons}}      \\ \hline
		\textnormal{Command}        & Output              \\ \hline
		\printcmd{tibtnmatrix}      & \tibtnmatrix{}      \\ \hline
		\printcmd{tibtnmatrixextra} & \tibtnmatrixextra{} \\ \hline
	\end{tabular}
\end{center}

\end{document}