Showing posts with label LaTeX. Show all posts
Quick and very simple piece of code in LaTeX which I suppose help you to create very ordinary own business card ;)
\documentclass[11pt]{article}
\usepackage[english]{babel}
\usepackage{polski}
\usepackage[cp1250]{inputenc}
\usepackage[none]{hyphenat}
\usepackage{graphicx}
\begin{document}
\begin{titlepage}
\newcommand{\HRule}{\rule{\linewidth}{0.5mm}} % Defines a new command for the horizontal lines, change thickness here
\center % Center everything on the page
%----------------------------------------------------------------------------------------
% HEADING SECTIONS
%----------------------------------------------------------------------------------------
%\textsc{\LARGE Dane rachunku bankowego}\\[1.5cm] % Name of your university/college
%\textsc{\Large Major Heading}\\[0.5cm] % Major heading such as course name
%\textsc{\large Minor Heading}\\[0.5cm] % Minor heading such as course title
%----------------------------------------------------------------------------------------
% TITLE SECTION
%----------------------------------------------------------------------------------------
\HRule \\[0.7cm]
{ \huge \bfseries Company Name}\\[0.4cm]
\HRule \\[0.9cm]
%----------------------------------------------------------------------------------------
% AUTHOR SECTION
%----------------------------------------------------------------------------------------
\large\emph{Details About Company}\\\vspace{0.5cm}
\large\emph{Facebook.com/CompanyPage }\\\vspace{0.5cm}
\large\emph{Twitter.com/CompanyPage}\\\vspace{0.5cm}
%----------------------------------------------------------------------------------------
\vfill % Fill the rest of the page with whitespace
\end{titlepage}
\end{document}
Reference :
[1] Business Card GarciaPL Pastebin.com
I would like to share with you an quick and I suppose painless piece of code to make your own table. Quite nice table i must add.
\begin{table}[ht]
\captionof{table}{Parametry zapytania dla Location SOAP API}
\begin{center}
\rowcolors{1}{lightgray}{}
%\begin{tabular}{|p{2cm}|p{12.8cm}|}
\begin{tabular}{| >{\centering\arraybackslash}m{2cm} | >{\centering\arraybackslash}m{12.8cm} |}
\hline
\multicolumn{1}{|c|}{\textbf{Parametr}} & \multicolumn{1}{c|}{\textbf{Opis wartości}} \\ \hline
address&Numer telefonu przeznaczony do zlokalizowania w formacie międzynarodowym (np. +48504500600)
lub krajowym (np. 504500600)\\ \hline
\end{tabular}
\end{center}
\end{table}
Result :
![]() |
| LaTeX table |
Reference :
[1] Source Pastebin.com
\usepackage[font=normalsize,format=plain,labelfont={bf,normalsize},textfont={it,normalsize}]{caption}
\definecolor{lightgray}{gray}{0.9}
\usepackage{listings}
\usepackage{courier}
\definecolor{gray}{rgb}{0.4,0.4,0.4}
\definecolor{darkblue}{rgb}{0.0,0.0,0.6}
\definecolor{cyan}{rgb}{0.0,0.6,0.6}
\lstset{
basicstyle=\footnotesize\ttfamily, % Standardschrift
%numbers=left, % Ort der Zeilennummern
numberstyle=\tiny, % Stil der Zeilennummern
%stepnumber=2, % Abstand zwischen den Zeilennummern
numbersep=5pt, % Abstand der Nummern zum Text
tabsize=2, % Groesse von Tabs
extendedchars=true, %
breaklines=true, % Zeilen werden Umgebrochen
keywordstyle=\color{red},
frame=b,
% keywordstyle=[1]\textbf, % Stil der Keywords
% keywordstyle=[2]\textbf, %
% keywordstyle=[3]\textbf, %
% keywordstyle=[4]\textbf, \sqrt{\sqrt{}} %
stringstyle=\color{white}\ttfamily, % Farbe der String
showspaces=false, % Leerzeichen anzeigen ?
showtabs=false, % Tabs anzeigen ?
xleftmargin=17pt,
framexleftmargin=17pt,
framexrightmargin=5pt,
framexbottommargin=4pt,
%backgroundcolor=\color{lightgray},
showstringspaces=false % Leerzeichen in Strings anzeigen ?
}
\lstdefinelanguage{XML}
{
morestring=[b]",
morestring=[s]{>}{<},
morecomment=[s]{},
stringstyle=\color{black},
identifierstyle=\color{darkblue},
keywordstyle=\color{cyan},
morekeywords={xmlns,version,type}% list your attributes here
}
\DeclareCaptionFont{white}{\color{white}}
\DeclareCaptionFormat{listing}{\colorbox{gray}{\parbox{\textwidth}{#1#2#3}}}
\captionsetup[lstlisting]{format=listing,labelfont=white,textfont=white}
Using in LaTeX code :
\lstinputlisting[label=soaplocationresponse,language=XML,caption=Odpowiedź Location SOAP API]{locationsoapresponse.xml}
Result :
![]() |
| LaTeX XML listing |
Reference :
[1] Listing XML GarciaPL Pastebin.com
[2] Using XML listing Pastebin.com
In this post i will put some very quick tips how create bold, italic and underline text in LaTeX.
Bold
\textbf{simple text} or \bf{simple text}
Italic
\textit{simple text} or \it{simple text}
Underline
I would like to show you a professional CV in LaTeX of course ;) Below I put a screenshot of it.
![]() |
| CV in LaTeX Page 1/2 |
![]() |
| CV in LaTeX Page 2/2 |
Quite pretty, right ? ;)
So, If you would like to have this one CV on your own, just write to me via Contact page ;) I will generate CV for you for very very small gift ;)
I speak Polish, so I wondering why not put some helpful information related with polish fonts in LaTeX. At the beginning I have to say that is very simple to do ;)
If you use Windows put :
\usepackage{polski}
\usepackage[cp1250]{inputenc}
If you use Linux put :
\usepackage{polski}
\usepackage[latin2]{inputenc}
If you use MacOS put :
\usepackage{polski}
\usepackage[macce]{inputenc}
Simple, isn't it?
Reference :
[1] Polonizacja LaTeX [PL]
[2] LaTeX Quide [PL]
This time I would like to share with code which will create below nice quotes in LaTeX of course ;)
![]() |
| LaTeX fancy quotes |
So, kindly add this snippet to your LaTeX project :
\makeatletter
\newif\if@right
\def\shadequote{\@righttrue\shadequote@i}
\def\shadequote@i{\begin{snugshade}\begin{quote}\openquote}
\def\endshadequote{%
\if@right\hfill\fi\closequote\end{quote}\end{snugshade}}
\@namedef{shadequote*}{\@rightfalse\shadequote@i}
\@namedef{endshadequote*}{\endshadequote}
\makeatother
and after all just use it :
\begin{shadequote}
\textit{Hello everybody!}
\par\emph{Tom Alexander - dyrektor generalny}
\end{shadequote}
Reference :
[1] Block quote with big quotation marks (TeX.StackExchange.com)
I'm very fascinated about document markup language and preparation system for the TeX typesetting program called LaTeX. I wrote using it my BSc thesis, curriculum vitae, cover letters, laboratory reports and many many more :-). Furthermore I am currently working on my MSc thesis of course writing it in LaTeX.
It has a lot of advantages - it is absolutely free, cross-platform, open-source (LPPL licence), automation generation components such as table of contents, bibliography, index etc., very good support for mathematical formulas and from community and obviously it can create documents look very nice and professionally in many widely known formats e.g. PDF, PostScript, HTML, DVI etc.
So, I am gona to show some piece of code which helps you create wonderful listing of your code in LaTeX ;) which is widely used for instance in books :
![]() |
| LaTeX code listing |
Copy and paste this style to your LaTeX project :
\usepackage{listings}
\usepackage{courier}
\lstset{
basicstyle=\footnotesize\ttfamily, % Standardschrift
%numbers=left, % Ort der Zeilennummern
numberstyle=\tiny, % Stil der Zeilennummern
%stepnumber=2, % Abstand zwischen den Zeilennummern
numbersep=5pt, % Abstand der Nummern zum Text
tabsize=2, % Groesse von Tabs
extendedchars=true, %
breaklines=true, % Zeilen werden Umgebrochen
keywordstyle=\color{red},
frame=b,
% keywordstyle=[1]\textbf, % Stil der Keywords
% keywordstyle=[2]\textbf, %
% keywordstyle=[3]\textbf, %
% keywordstyle=[4]\textbf, \sqrt{\sqrt{}} %
stringstyle=\color{white}\ttfamily, % Farbe der String
showspaces=false, % Leerzeichen anzeigen ?
showtabs=false, % Tabs anzeigen ?
xleftmargin=17pt,
framexleftmargin=17pt,
framexrightmargin=5pt,
framexbottommargin=4pt,
%backgroundcolor=\color{lightgray},
showstringspaces=false % Leerzeichen in Strings anzeigen ?
}
\lstloadlanguages{% Check Dokumentation for further languages ...
%[Visual]Basic
%Pascal
%C
%C++
%XML
%HTML
Java
}
%\DeclareCaptionFont{blue}{\color{blue}}
%\captionsetup[lstlisting]{singlelinecheck=false, \
labelfont={blue}, textfont={blue}}
\usepackage{caption}
\DeclareCaptionFont{white}{\color{white}}
\DeclareCaptionFormat{listing}{\colorbox[cmyk] \
{0.43, 0.35, 0.35,0.01}{\parbox{\textwidth} \
{\hspace{15pt}#1#2#3}}}
\captionsetup[lstlisting]{format=listing,labelfont=white, \
textfont=white,singlelinecheck=false, margin=0pt, \
font={bf,footnotesize}}
Then use this code in LaTeX to invoke source code listing :
\lstinputlisting[label=samplecode,caption=Description]{code/foo.java}
Reference :
[1] MHK's Blog
[2] LaTeX source code listing like in professional books (Stackoverflow)







