summaryrefslogtreecommitdiff
path: root/macros/latex/contrib/uspatent/tex
diff options
context:
space:
mode:
authorNorbert Preining <norbert@preining.info>2019-09-02 13:46:59 +0900
committerNorbert Preining <norbert@preining.info>2019-09-02 13:46:59 +0900
commite0c6872cf40896c7be36b11dcc744620f10adf1d (patch)
tree60335e10d2f4354b0674ec22d7b53f0f8abee672 /macros/latex/contrib/uspatent/tex
Initial commit
Diffstat (limited to 'macros/latex/contrib/uspatent/tex')
-rw-r--r--macros/latex/contrib/uspatent/tex/Drawings.lyx179
-rw-r--r--macros/latex/contrib/uspatent/tex/Drawings.tex28
-rw-r--r--macros/latex/contrib/uspatent/tex/PatentApplication.lyx580
-rw-r--r--macros/latex/contrib/uspatent/tex/PatentApplication.pdfbin0 -> 190062 bytes
-rw-r--r--macros/latex/contrib/uspatent/tex/PatentApplication.tex117
-rw-r--r--macros/latex/contrib/uspatent/tex/TpXDrawing.tpx58
-rw-r--r--macros/latex/contrib/uspatent/tex/VisioDrawing.pdfbin0 -> 55216 bytes
-rw-r--r--macros/latex/contrib/uspatent/tex/VisioDrawing.vsdbin0 -> 44544 bytes
-rw-r--r--macros/latex/contrib/uspatent/tex/VisioMainDrawing.vsdbin0 -> 15360 bytes
-rw-r--r--macros/latex/contrib/uspatent/tex/uspatent.cls729
-rw-r--r--macros/latex/contrib/uspatent/tex/uspatent.layout634
11 files changed, 2325 insertions, 0 deletions
diff --git a/macros/latex/contrib/uspatent/tex/Drawings.lyx b/macros/latex/contrib/uspatent/tex/Drawings.lyx
new file mode 100644
index 0000000000..59c1e8e3b5
--- /dev/null
+++ b/macros/latex/contrib/uspatent/tex/Drawings.lyx
@@ -0,0 +1,179 @@
+#LyX 2.0 created this file. For more info see http://www.lyx.org/
+\lyxformat 413
+\begin_document
+\begin_header
+\textclass uspatent
+\begin_preamble
+\def\patentOfficeMode{true}
+\end_preamble
+\use_default_options false
+\maintain_unincluded_children false
+\language english
+\language_package default
+\inputencoding auto
+\fontencoding global
+\font_roman default
+\font_sans default
+\font_typewriter default
+\font_default_family default
+\use_non_tex_fonts false
+\font_sc false
+\font_osf false
+\font_sf_scale 100
+\font_tt_scale 100
+
+\graphics pdftex
+\default_output_format pdf2
+\output_sync 0
+\bibtex_command default
+\index_command default
+\float_placement th
+\paperfontsize default
+\spacing single
+\use_hyperref false
+\pdf_bookmarks true
+\pdf_bookmarksnumbered false
+\pdf_bookmarksopen false
+\pdf_bookmarksopenlevel 1
+\pdf_breaklinks false
+\pdf_pdfborder false
+\pdf_colorlinks false
+\pdf_backref false
+\pdf_pdfusetitle true
+\pdf_quoted_options "hyperindex=true,pdfauthor= {\pdfAuthor},pdftitle= {\pdfTitle},bookmarks=true,extension= pdf,linkcolor=black,colorlinks=true,hyperfootnotes=false,pdffitwindow=true,pdftoolbar=true,pdfmenubar=true,debug=false,pagebackref=true"
+\papersize default
+\use_geometry false
+\use_amsmath 1
+\use_esint 1
+\use_mhchem 1
+\use_mathdots 1
+\cite_engine basic
+\use_bibtopic false
+\use_indices false
+\paperorientation portrait
+\suppress_date false
+\use_refstyle 0
+\index Index
+\shortcut idx
+\color #008000
+\end_index
+\secnumdepth 3
+\tocdepth -1
+\paragraph_separation indent
+\paragraph_indentation default
+\quotes_language english
+\papercolumns 1
+\papersides 2
+\paperpagestyle default
+\bulletLaTeX 0 "\,"
+\tracking_changes false
+\output_changes false
+\html_math_output 0
+\html_css_as_file 0
+\html_be_strict false
+\end_header
+
+\begin_body
+
+\begin_layout FigureDefinition
+VisioDrawing
+\end_layout
+
+\begin_layout FigureExtension
+pdf
+\end_layout
+
+\begin_layout FigureDescription
+is an example drawing created in Visio
+\end_layout
+
+\begin_layout AnnotationDefinition
+Widget
+\end_layout
+
+\begin_layout AnnotationName
+widget
+\end_layout
+
+\begin_layout AnnotationDescription
+a widget in the Visio drawing
+\end_layout
+
+\begin_layout AnnotationDefinition
+Thing
+\end_layout
+
+\begin_layout AnnotationName
+thing
+\end_layout
+
+\begin_layout AnnotationDescription
+a thing in the visio drawing
+\end_layout
+
+\begin_layout AnnotationDefinition
+WidgetThingConnection
+\end_layout
+
+\begin_layout AnnotationName
+connection
+\end_layout
+
+\begin_layout AnnotationDescription
+the arrow connecting the widget and the thing
+\end_layout
+
+\begin_layout FigureDefinition
+TpXDrawing
+\end_layout
+
+\begin_layout FigureExtension
+tpx
+\end_layout
+
+\begin_layout FigureCaption
+PRIOR ART
+\end_layout
+
+\begin_layout FigureDescription
+is an example drawing created in TpX
+\end_layout
+
+\begin_layout AnnotationDefinition
+input
+\end_layout
+
+\begin_layout AnnotationName
+input
+\end_layout
+
+\begin_layout AnnotationDescription
+the input
+\end_layout
+
+\begin_layout AnnotationDefinition
+output
+\end_layout
+
+\begin_layout AnnotationName
+output
+\end_layout
+
+\begin_layout AnnotationDescription
+the output
+\end_layout
+
+\begin_layout AnnotationDefinition
+mathProcessor
+\end_layout
+
+\begin_layout AnnotationName
+math processor
+\end_layout
+
+\begin_layout AnnotationDescription
+the math procesor
+\end_layout
+
+\end_body
+\end_document
diff --git a/macros/latex/contrib/uspatent/tex/Drawings.tex b/macros/latex/contrib/uspatent/tex/Drawings.tex
new file mode 100644
index 0000000000..dd51a1cafc
--- /dev/null
+++ b/macros/latex/contrib/uspatent/tex/Drawings.tex
@@ -0,0 +1,28 @@
+\figureDefinition{VisioDrawing}
+\figureExtension{pdf}
+\figureDescription{is an example drawing created in Visio}
+
+\annotationDefinition{Widget}
+\annotationName{widget}
+\annotationDescription{a widget in the Visio drawing}
+\annotationDefinition{Thing}
+\annotationName{thing}
+\annotationDescription{a thing in the visio drawing}
+\annotationDefinition{WidgetThingConnection}
+\annotationName{connection}
+\annotationDescription{the arrow connecting the widget and the thing}
+
+\figureDefinition{TpXDrawing}
+\figureExtension{tpx}
+\figureCaption{PRIOR ART}
+\figureDescription{is an example drawing created in TpX}
+
+\annotationDefinition{input}
+\annotationName{input}
+\annotationDescription{the input}
+\annotationDefinition{output}
+\annotationName{output}
+\annotationDescription{the output}
+\annotationDefinition{mathProcessor}
+\annotationName{math processor}
+\annotationDescription{the math procesor}
diff --git a/macros/latex/contrib/uspatent/tex/PatentApplication.lyx b/macros/latex/contrib/uspatent/tex/PatentApplication.lyx
new file mode 100644
index 0000000000..44a9258651
--- /dev/null
+++ b/macros/latex/contrib/uspatent/tex/PatentApplication.lyx
@@ -0,0 +1,580 @@
+#LyX 2.0 created this file. For more info see http://www.lyx.org/
+\lyxformat 413
+\begin_document
+\begin_header
+\textclass uspatent
+\begin_preamble
+
+\end_preamble
+\use_default_options false
+\maintain_unincluded_children false
+\language english
+\language_package default
+\inputencoding auto
+\fontencoding global
+\font_roman default
+\font_sans default
+\font_typewriter default
+\font_default_family default
+\use_non_tex_fonts false
+\font_sc false
+\font_osf false
+\font_sf_scale 100
+\font_tt_scale 100
+
+\graphics pdftex
+\default_output_format pdf2
+\output_sync 0
+\bibtex_command default
+\index_command default
+\float_placement th
+\paperfontsize default
+\spacing single
+\use_hyperref false
+\pdf_bookmarks true
+\pdf_bookmarksnumbered false
+\pdf_bookmarksopen false
+\pdf_bookmarksopenlevel 1
+\pdf_breaklinks false
+\pdf_pdfborder false
+\pdf_colorlinks false
+\pdf_backref false
+\pdf_pdfusetitle true
+\pdf_quoted_options "hyperindex=true,pdfauthor= {\pdfAuthor},pdftitle= {\pdfTitle},bookmarks=true,extension= pdf,linkcolor=black,colorlinks=true,hyperfootnotes=false,pdffitwindow=true,pdftoolbar=true,pdfmenubar=true,debug=false,pagebackref=true"
+\papersize default
+\use_geometry false
+\use_amsmath 1
+\use_esint 1
+\use_mhchem 1
+\use_mathdots 1
+\cite_engine basic
+\use_bibtopic false
+\use_indices false
+\paperorientation portrait
+\suppress_date false
+\use_refstyle 0
+\branch test
+\selected 0
+\filename_suffix 0
+\color #faf0e6
+\end_branch
+\index Index
+\shortcut idx
+\color #008000
+\end_index
+\secnumdepth 4
+\tocdepth 4
+\paragraph_separation indent
+\paragraph_indentation default
+\quotes_language english
+\papercolumns 1
+\papersides 2
+\paperpagestyle default
+\bulletLaTeX 0 "\,"
+\tracking_changes false
+\output_changes false
+\html_math_output 0
+\html_css_as_file 0
+\html_be_strict false
+\end_header
+
+\begin_body
+
+\begin_layout Standard
+\begin_inset Note Note
+status open
+
+\begin_layout Plain Layout
+%%
+\end_layout
+
+\begin_layout Plain Layout
+%% This is file `PatentApplication.lyx',
+\end_layout
+
+\begin_layout Plain Layout
+%% Version 1.0
+\end_layout
+
+\begin_layout Plain Layout
+%%
+\end_layout
+
+\begin_layout Plain Layout
+%% Author: Peter J.
+ Pupalaikis (pete_pope at hotmail dot com)
+\end_layout
+
+\begin_layout Plain Layout
+%% Copyright 2012 Peter J.
+ Pupalaikis
+\end_layout
+
+\begin_layout Plain Layout
+%%
+\end_layout
+
+\begin_layout Plain Layout
+%% This work may be distributed and/or modified under the
+\end_layout
+
+\begin_layout Plain Layout
+%% conditions of the LaTeX Project Public License, either
+\end_layout
+
+\begin_layout Plain Layout
+%% version 1.3 of this license or (at your option) any
+\end_layout
+
+\begin_layout Plain Layout
+%% later version.
+\end_layout
+
+\begin_layout Plain Layout
+%% The latest version of the license is in
+\end_layout
+
+\begin_layout Plain Layout
+%% http://www.latex-project.org/lppl.txt
+\end_layout
+
+\begin_layout Plain Layout
+%% and version 1.3 or later is part of all distributions of
+\end_layout
+
+\begin_layout Plain Layout
+%% LaTeX version 2003/06/01 or later.
+\end_layout
+
+\begin_layout Plain Layout
+%%
+\end_layout
+
+\begin_layout Plain Layout
+%% This work consists of the files listed in the README file.
+\end_layout
+
+\begin_layout Plain Layout
+%%
+\end_layout
+
+\end_inset
+
+
+\end_layout
+
+\begin_layout AssigneeName
+Assignee Name
+\end_layout
+
+\begin_layout AssigneeAddress
+Assignee Address
+\end_layout
+
+\begin_layout AssigneeCity
+Assignee City, State, Zip
+\end_layout
+
+\begin_layout AssigneePhone
+Assignee Phone
+\end_layout
+
+\begin_layout DocketNumber
+Docket Number
+\end_layout
+
+\begin_layout LawyerName
+Patent Lawyer Name
+\end_layout
+
+\begin_layout LawyerNumber
+Reg #:99,999
+\end_layout
+
+\begin_layout LawyerPhone
+Patent Lawyer Phone
+\end_layout
+
+\begin_layout OtherInventor
+Another Inventor
+\end_layout
+
+\begin_layout OtherInventor
+Yet Another Inventor
+\end_layout
+
+\begin_layout Version
+0.0
+\end_layout
+
+\begin_layout ApplicationMode
+
+\end_layout
+
+\begin_layout Standard
+\begin_inset CommandInset include
+LatexCommand include
+filename "Drawings.lyx"
+
+\end_inset
+
+
+\end_layout
+
+\begin_layout Title
+Invention Name Not Yet Defined
+\end_layout
+
+\begin_layout Date
+Date of this version
+\end_layout
+
+\begin_layout Inventor
+First Named Inventor
+\end_layout
+
+\begin_layout PatentSection
+Field of the Invention
+\end_layout
+
+\begin_layout PatentParagraph
+Describe the field of the invention like...
+\end_layout
+
+\begin_layout PatentParagraph
+The present invention relates to \SpecialChar \ldots{}
+ and in particular to \SpecialChar \ldots{}
+
+\end_layout
+
+\begin_layout PatentParagraph
+In other words, the basic types of things that the invention improves or
+ is implemented in.
+\end_layout
+
+\begin_layout PatentSection
+Background of the Invention
+\end_layout
+
+\begin_layout PatentParagraph
+Describe the past.
+ Focus on problems that you will be solving.
+ Talk about prior-art in detail to describe what has been done before and
+ what the problems are.
+ You are telling a story that inevitably leads up to ending statements like:
+\end_layout
+
+\begin_layout PatentParagraph
+What is needed is\SpecialChar \ldots{}
+
+\end_layout
+
+\begin_layout PatentParagraph
+The things that are needed will be put forth as solutions in the next section.
+\end_layout
+
+\begin_layout PatentSection
+Objects of the Invention
+\end_layout
+
+\begin_layout PatentParagraph
+It is an object of this invention to \SpecialChar \ldots{}
+ Note that the objects should match
+ the things that are needed as described in the last section.
+ Do not describe the invention here, just the problems that will be solved
+ or the utility of the invention.
+\end_layout
+
+\begin_layout PatentParagraph
+Still other objects and advantages of the invention will in part be obvious
+ and will in part be apparent from the specification and drawings.
+
+\end_layout
+
+\begin_layout PatentSection
+Summary of the Invention
+\end_layout
+
+\begin_layout PatentParagraph
+In order to overcome blank, we do\SpecialChar \ldots{}
+
+\end_layout
+
+\begin_layout PatentParagraph
+The invention accordingly comprises the several steps and the relation of
+ one or more of such steps with respect to each of the others, and the apparatus
+ embodying features of construction, combinations of elements and arrangement
+ of parts that are adapted to affect such steps, all is exemplified in the
+ following detailed disclosure, and the scope of the invention will be indicated
+ in the claims.
+\end_layout
+
+\begin_layout DrawingsDescriptionSection
+\noindent
+
+\end_layout
+
+\begin_layout PatentSection
+Detailed Description of the Preferred Embodiments
+\end_layout
+
+\begin_layout PatentParagraph
+The details of the invention go here.
+ I will use this area to make reference to the drawings so you can see how
+ it's done.
+\end_layout
+
+\begin_layout PatentParagraph
+The arrangement in
+\begin_inset Flex FigureReference
+status open
+
+\begin_layout Plain Layout
+
+VisioDrawing
+\end_layout
+
+\end_inset
+
+ shows an exemplary arrangement of a preferred embodiment.
+ In
+\begin_inset Flex FigureReference
+status collapsed
+
+\begin_layout Plain Layout
+
+VisioDrawing
+\end_layout
+
+\end_inset
+
+, one sees a
+\begin_inset Flex Annotation+Name
+status collapsed
+
+\begin_layout Plain Layout
+
+Widget
+\end_layout
+
+\end_inset
+
+ and a
+\begin_inset Flex Annotation+Name
+status collapsed
+
+\begin_layout Plain Layout
+
+Thing
+\end_layout
+
+\end_inset
+
+ with a preferable
+\begin_inset Flex Annotation+Name
+status collapsed
+
+\begin_layout Plain Layout
+
+WidgetThingConnection
+\end_layout
+
+\end_inset
+
+ that enables the
+\begin_inset Flex Annotation+Name
+status collapsed
+
+\begin_layout Plain Layout
+
+Thing
+\end_layout
+
+\end_inset
+
+ to process the data coming from the
+\begin_inset Flex Annotation+Name
+status collapsed
+
+\begin_layout Plain Layout
+
+Widget
+\end_layout
+
+\end_inset
+
+.
+ I think you get the idea.
+\end_layout
+
+\begin_layout PatentParagraph
+You can either write:
+\begin_inset Flex Annotation+Name
+status collapsed
+
+\begin_layout Plain Layout
+
+Thing
+\end_layout
+
+\end_inset
+
+ or you can write thing
+\begin_inset space ~
+\end_inset
+
+
+\begin_inset Flex Annotation
+status collapsed
+
+\begin_layout Plain Layout
+
+Thing
+\end_layout
+
+\end_inset
+
+.
+ They both produce the same thing.
+\end_layout
+
+\begin_layout PatentParagraph
+I can put things in the margin of the application in draft mode like this:
+
+\begin_inset Flex PatentComment
+status collapsed
+
+\begin_layout Plain Layout
+
+a comment like this appears in the margin when the application is printed
+ in draft mode
+\end_layout
+
+\end_inset
+
+
+\end_layout
+
+\begin_layout PatentParagraph
+Note that you make and refer to equations like this:
+\end_layout
+
+\begin_layout Standard
+\begin_inset Formula
+\begin{equation}
+E=mc^{2}\label{eq:energy}
+\end{equation}
+
+\end_inset
+
+
+\end_layout
+
+\begin_layout PatentParagraph
+One of my favorite equations is:
+\end_layout
+
+\begin_layout Standard
+\begin_inset Formula
+\begin{equation}
+e^{j\theta}=\cos\left(\theta\right)+j\cdot\sin\left(\theta\right)\label{eq:euler}
+\end{equation}
+
+\end_inset
+
+
+\end_layout
+
+\begin_layout PatentParagraph
+We refer to the first equation as
+\begin_inset CommandInset ref
+LatexCommand formatted
+reference "eq:energy"
+
+\end_inset
+
+ and the second as
+\begin_inset CommandInset ref
+LatexCommand formatted
+reference "eq:euler"
+
+\end_inset
+
+.
+ The second equation
+\begin_inset CommandInset ref
+LatexCommand formatted
+reference "eq:euler"
+
+\end_inset
+
+ is Euler's equation.
+\end_layout
+
+\begin_layout PatentParagraph
+It will thus be seen that the objects set forth above, among those made
+ apparent from the preceding description, are efficiently attained and,
+ because certain changes may be made in carrying out the above method and
+ in the construction(s) set forth without departing from the spirit and
+ scope of the invention, it is intended that all matter contained in the
+ above description and shown in the accompanying drawings shall be interpreted
+ as illustrative and not in a limiting sense.
+\end_layout
+
+\begin_layout PatentParagraph
+It is also to be understood that the following claims are intended to cover
+ all of the generic and specific features of the invention herein described
+ and all statements of the scope of the invention which, as a matter of
+ language, might be said to fall therebetween.
+\end_layout
+
+\begin_layout ClaimsStart
+
+\end_layout
+
+\begin_layout Claim
+Claim1
+\end_layout
+
+\begin_layout Standard
+This is an independent claim.
+\end_layout
+
+\begin_layout Claim
+Claim2
+\end_layout
+
+\begin_layout Standard
+The method of
+\begin_inset Flex ClaimReference
+status open
+
+\begin_layout Plain Layout
+
+Claim1
+\end_layout
+
+\end_inset
+
+ further comprising\SpecialChar \ldots{}
+
+\end_layout
+
+\begin_layout ClaimsEnd
+
+\end_layout
+
+\begin_layout PatentSection
+Abstract
+\end_layout
+
+\begin_layout Standard
+A simple statement of what the invention pertains to
+\end_layout
+
+\begin_layout DrawingsSection
+
+\end_layout
+
+\end_body
+\end_document
diff --git a/macros/latex/contrib/uspatent/tex/PatentApplication.pdf b/macros/latex/contrib/uspatent/tex/PatentApplication.pdf
new file mode 100644
index 0000000000..f4d110fe28
--- /dev/null
+++ b/macros/latex/contrib/uspatent/tex/PatentApplication.pdf
Binary files differ
diff --git a/macros/latex/contrib/uspatent/tex/PatentApplication.tex b/macros/latex/contrib/uspatent/tex/PatentApplication.tex
new file mode 100644
index 0000000000..a2bf3eed73
--- /dev/null
+++ b/macros/latex/contrib/uspatent/tex/PatentApplication.tex
@@ -0,0 +1,117 @@
+%%
+%% This is file `PatentApplication.tex',
+%%
+%%
+%% Author: Peter J. Pupalaikis (pete_pope at hotmail dot com)
+%% Copyright 2012 Peter J. Pupalaikis
+%% Version 1.0
+%%
+%% This work may be distributed and/or modified under the
+%% conditions of the LaTeX Project Public License, either
+%% version 1.3 of this license or (at your option) any
+%% later version.
+%% The latest version of the license is in
+%% http://www.latex-project.org/lppl.txt
+%% and version 1.3 or later is part of all distributions of
+%% LaTeX version 2003/06/01 or later.
+%%
+%% This work consists of the files listed in the README file.
+%%
+\documentclass[english]{uspatent}
+\begin{document}
+
+\setAssigneeName{Assignee Name}
+\setAssigneeAddress{Assignee Address}
+\setAssigneeCity{Assignee City, State, Zip}
+\setAssigneePhone{Assignee Phone}
+\setDocketNumber{Docket Number}
+\setLawyerName{Patent Laywer Name}
+\setLawyerNumber{Patent Lawer Reg. Number}
+\setLawyerPhone{Patent Lawyer Phone}
+\setOtherInventor{Another Inventor}
+\setOtherInventor{Yet Another Inventor}
+\setDocumentVersion{0.0}
+\setPrintingModeApplication
+
+\include{Drawings}
+
+\title{Invention Name Not Yet Defined}
+\date{Date of this version}
+\inventor{First Named Inventor}
+
+\maketitle
+
+\patentSection{Field of the Invention}
+
+\patentParagraph Describe the field of the invention like...
+
+\patentParagraph The present invention relates to \ldots and in particular to \ldots
+
+\patentParagraph In other words, the basic types of things that the invention improves or is implemented in.
+
+\patentSection{Background of the Invention}
+
+\patentParagraph Describe the past. Focus on problems that you will be solving. Talk about prior-art in detail to describe what has been done before and what the problems are. You are telling a story that inevitably leads up to ending statements like:
+
+\patentParagraph What is needed is\ldots
+
+\patentParagraph The things that are needed will be put forth as solutions in the next section.
+
+\patentSection{Objects of the Invention}
+
+\patentParagraph It is an object of this invention to \ldots Note that the objects should match the things that are needed as described in the last section. Do not describe the invention here, just the problems that will be solved or the utility of the invention.
+
+\patentParagraph Still other objects and advantages of the invention will in part be obvious and will in part be apparent from the specification and drawings.
+
+\patentSection{Summary of the Invention}
+
+\patentParagraph In order to overcome \ldots, we do\ldots
+
+\patentParagraph The invention accordingly comprises the several steps and the relation of one or more of such steps with respect to each of the others, and the apparatus embodying features of construction, combinations of elements and arrangement of parts that are adapted to affect such steps, all is exemplified in the following detailed disclosure, and the scope of the invention will be indicated in the claims.
+
+\patentDrawingDescriptions
+
+\patentSection{Detailed Description of the Preferred Embodiments}
+
+\patentParagraph The details of the invention go here. I will use this area to make reference to the drawings so you can see how it's done.
+
+\patentParagraph The arrangement in \referencePatentFigure{VisioDrawing} shows an exemplary arrangement of a preferred embodiment. In \referencePatentFigure{VisioDrawing}, one sees a \annotateWithName{Widget} and a \annotateWithName{Thing} with a preferable \annotateWithName{WidgetThingConnection} that enables the \annotateWithName{Thing} to process the data coming from the \annotateWithName{Widget}. I think you get the idea. You can refer to the number as \annotationNumberReference{Widget} and if you need it underlined in a drawing, use \annotationNumberReferenceUnderlined{Widget}.
+
+\patentParagraph You can either write: \annotateWithName{Thing} or you can write thing~\annotate{Thing}. They both produce the same thing.
+
+\patentParagraph Note that you make and refer to equations like this:
+
+\begin{equation}
+E=mc^{2}\label{eq:energy}
+\end{equation}
+
+\patentParagraph One of my favorite equations is:
+
+\begin{equation}
+e^{j\theta}=\cos\left(\theta\right)+j\cdot\sin\left(\theta\right)\label{eq:euler}
+\end{equation}
+
+\patentParagraph We refer to the first equation as \prettyref{eq:energy} and the second as \prettyref{eq:euler}. The second equation \prettyref{eq:euler} is Euler's equation.
+
+\patentParagraph It will thus be seen that the objects set forth above, among those made apparent from the preceding description, are efficiently attained and, because certain changes may be made in carrying out the above method and in the construction(s) set forth without departing from the spirit and scope of the invention, it is intended that all matter contained in the above description and shown in the accompanying drawings shall be interpreted as illustrative and not in a limiting sense.
+
+\patentParagraph It is also to be understood that the following claims are intended to cover all of the generic and specific features of the invention herein described and all statements of the scope of the invention which, as a matter of language, might be said to fall therebetween.
+
+\patentClaimsStart
+
+\beginClaim{Claim1}
+
+This is an independent claim.
+
+\beginClaim{Claim2}
+
+The method of \claimRef{Claim1} further comprising\ldots
+
+\patentClaimsEnd
+
+\patentSection{Abstract}
+
+A simple statement of what the invention pertains to\ldots
+
+\patentDrawings
+\end{document}
diff --git a/macros/latex/contrib/uspatent/tex/TpXDrawing.tpx b/macros/latex/contrib/uspatent/tex/TpXDrawing.tpx
new file mode 100644
index 0000000000..a5fcb2f03a
--- /dev/null
+++ b/macros/latex/contrib/uspatent/tex/TpXDrawing.tpx
@@ -0,0 +1,58 @@
+%<TpX v="5" TeXFormat="none" PdfTeXFormat="tikz" ArrowsSize="0.7" StarsSize="1" DefaultFontHeight="5" DefaultSymbolSize="30" ApproximationPrecision="0.01" PicScale="1" Border="2" BitmapRes="20000" HatchingStep="2" DottedSize="0.5" DashSize="1" LineWidth="0.3" TeXFigure="none" FontSizeInTeX="0">
+% <rect x="-1.45056E-6" y="9.99999" w="100" h="40" li="none" fill="white"/>
+% <arc x="17" y="30" d="10" a1="4.71239" a2="7.85398"/>
+% <arc x="12" y="30" d="10" a1="1.5708" a2="4.71239"/>
+% <line x1="12" y1="35" x2="17" y2="35"/>
+% <line x1="12" y1="25" x2="17" y2="25"/>
+% <text x="14.5" y="29" t="Input" h="4" halign="c"/>
+% <line x1="22" y1="30" x2="32" y2="30" arr2="h44"/>
+% <rect x="32" y="25" w="35" h="10" fill="white"/>
+% <text x="38.6907" y="29.104" t="1/2-x^2" tex="$\frac{1}{2}-x^2$" h="5"/>
+% <arc x="87" y="30" d="10" a1="4.71239" a2="7.85398"/>
+% <arc x="82" y="30" d="10" a1="1.5708" a2="4.71239"/>
+% <line x1="82" y1="35" x2="87" y2="35"/>
+% <line x1="82" y1="25" x2="87" y2="25"/>
+% <text x="84.5" y="29" t="Output" h="4" halign="c"/>
+% <line x1="67" y1="30" x2="77" y2="30" arr2="h44"/>
+% <line x1="17" y1="35" x2="26" y2="42"/>
+% <text x="26" y="41" t="input" tex="\annotateNoBrackets{input}" h="4"/>
+% <line x1="41" y1="25" x2="50" y2="15"/>
+% <text x="50" y="14" t="math processor" tex="\annotateNoBrackets{mathProcessor}" h="4"/>
+% <line x1="85" y1="20" x2="82" y2="25"/>
+% <text x="85" y="19" t="output" tex="\annotateNoBrackets{output}" h="4"/>
+%</TpX>
+\centering
+\ifpdf
+\begin{tikzpicture}[x=1.00mm, y=1.00mm, inner xsep=0pt, inner ysep=0pt, outer xsep=0pt, outer ysep=0pt]
+\path[line width=0mm] (-2.00,8.00) rectangle +(104.00,44.00);
+\definecolor{F}{rgb}{1,1,1}
+\path[fill=F] (0.00,10.00) rectangle +(100.00,40.00);
+\definecolor{L}{rgb}{0,0,0}
+\path[line width=0.30mm, draw=L] (17.00,25.00) arc (-90:90:5.00mm);
+\path[line width=0.30mm, draw=L] (12.00,35.00) arc (90:270:5.00mm);
+\path[line width=0.30mm, draw=L] (12.00,35.00) -- (17.00,35.00);
+\path[line width=0.30mm, draw=L] (12.00,25.00) -- (17.00,25.00);
+\draw(14.50,29.00) node[anchor=base]{Input};
+\path[line width=0.30mm, draw=L] (22.00,30.00) -- (32.00,30.00);
+\definecolor{F}{rgb}{0,0,0}
+\path[line width=0.30mm, draw=L, fill=F] (32.00,30.00) -- (29.20,30.70) -- (29.20,29.30) -- (32.00,30.00) -- cycle;
+\definecolor{F}{rgb}{1,1,1}
+\path[line width=0.30mm, draw=L, fill=F] (32.00,25.00) rectangle +(35.00,10.00);
+\draw(38.69,29.10) node[anchor=base west]{$\frac{1}{2}-x^2$};
+\path[line width=0.30mm, draw=L] (87.00,25.00) arc (-90:90:5.00mm);
+\path[line width=0.30mm, draw=L] (82.00,35.00) arc (90:270:5.00mm);
+\path[line width=0.30mm, draw=L] (82.00,35.00) -- (87.00,35.00);
+\path[line width=0.30mm, draw=L] (82.00,25.00) -- (87.00,25.00);
+\draw(84.50,29.00) node[anchor=base]{Output};
+\path[line width=0.30mm, draw=L] (67.00,30.00) -- (77.00,30.00);
+\definecolor{F}{rgb}{0,0,0}
+\path[line width=0.30mm, draw=L, fill=F] (77.00,30.00) -- (74.20,30.70) -- (74.20,29.30) -- (77.00,30.00) -- cycle;
+\path[line width=0.30mm, draw=L] (17.00,35.00) -- (26.00,42.00);
+\draw(26.00,41.00) node[anchor=base west]{\annotateNoBrackets{input}};
+\path[line width=0.30mm, draw=L] (41.00,25.00) -- (50.00,15.00);
+\draw(50.00,14.00) node[anchor=base west]{\annotateNoBrackets{mathProcessor}};
+\path[line width=0.30mm, draw=L] (85.00,20.00) -- (82.00,25.00);
+\draw(85.00,19.00) node[anchor=base west]{\annotateNoBrackets{output}};
+\end{tikzpicture}%
+\else
+\fi
diff --git a/macros/latex/contrib/uspatent/tex/VisioDrawing.pdf b/macros/latex/contrib/uspatent/tex/VisioDrawing.pdf
new file mode 100644
index 0000000000..eacbf852bc
--- /dev/null
+++ b/macros/latex/contrib/uspatent/tex/VisioDrawing.pdf
Binary files differ
diff --git a/macros/latex/contrib/uspatent/tex/VisioDrawing.vsd b/macros/latex/contrib/uspatent/tex/VisioDrawing.vsd
new file mode 100644
index 0000000000..87e89ad1e3
--- /dev/null
+++ b/macros/latex/contrib/uspatent/tex/VisioDrawing.vsd
Binary files differ
diff --git a/macros/latex/contrib/uspatent/tex/VisioMainDrawing.vsd b/macros/latex/contrib/uspatent/tex/VisioMainDrawing.vsd
new file mode 100644
index 0000000000..f92fe42ffe
--- /dev/null
+++ b/macros/latex/contrib/uspatent/tex/VisioMainDrawing.vsd
Binary files differ
diff --git a/macros/latex/contrib/uspatent/tex/uspatent.cls b/macros/latex/contrib/uspatent/tex/uspatent.cls
new file mode 100644
index 0000000000..65c36bba35
--- /dev/null
+++ b/macros/latex/contrib/uspatent/tex/uspatent.cls
@@ -0,0 +1,729 @@
+%%
+%% This is file `uspatent.cls',
+%%
+%%
+%% Author: Peter J. Pupalaikis (pete_pope at hotmail dot com)
+%% Copyright 2012 Peter J. Pupalaikis
+%% Version 1.0
+%%
+%% This work may be distributed and/or modified under the
+%% conditions of the LaTeX Project Public License, either
+%% version 1.3 of this license or (at your option) any
+%% later version.
+%% The latest version of the license is in
+%% http://www.latex-project.org/lppl.txt
+%% and version 1.3 or later is part of all distributions of
+%% LaTeX version 2003/06/01 or later.
+%%
+%% This work consists of the files listed in the README file.
+%%
+\NeedsTeXFormat{LaTeX2e}
+\ProvidesClass{uspatent}%
+ [2012/06/09 v1.0 U.S. Patent Application Class]
+%\DeclareOption*{\PassOptionsToClass{\CurrentOption}{memoir}}
+%\ProcessOptions
+\LoadClass[letterpaper,12pt]{memoir}[1996/10/24]
+
+\newif\ifPatentOfficeMode
+\PatentOfficeModetrue
+
+\newcommand{\setAssigneeName}{\def\assigneeName}
+\newcommand{\setAssigneeAddress}{\def\assigneeAddress}
+\newcommand{\setAssigneeCity}{\def\assigneeCity}
+\newcommand{\setAssigneePhone}{\def\assigneePhone}
+\newcommand{\setDocketNumber}{\def\patentNumber}
+\newcommand{\setLawyerName}{\def\patentLawyerName}
+\newcommand{\setLawyerNumber}{\def\patentLawyerNumber}
+\newcommand{\setLawyerPhone}{\def\patentLawyerPhone}
+\newcommand{\setOtherInventor}[1]{\otherInventor{#1}}
+\newcommand{\setDocumentVersion}{\def\patentDocumentVersion}
+\newcommand{\setPrintingModeDraft}{\PatentOfficeModefalse}
+\newcommand{\setPrintingModeApplication}{\PatentOfficeModetrue}
+\newcommand{\inventor}{\author}
+
+\settrimmedsize{11in}{8.5in}{*}
+\setlength{\trimtop}{0pt}
+\setlength{\trimedge}{0pt}
+\settypeblocksize{8.5in}{36pc}{*}
+\setulmargins{1.5in}{*}{*}
+\setlrmargins{*}{*}{1}
+\setmarginnotes{17pt}{51pt}{\onelineskip}
+\setheadfoot{5\onelineskip}{3\onelineskip}
+\setheaderspaces{*}{2\onelineskip}{*}
+\checkandfixthelayout
+\captiondelim{}
+
+\ifpdf
+\usepackage[pdftex]{graphicx}
+%No Commas in the PDF Title!?!
+\usepackage[
+hyperindex=true,
+pdfusetitle,
+bookmarks=true,
+extension= pdf,
+linkcolor=black,
+colorlinks=true,
+hyperfootnotes=false,
+pdffitwindow=true,
+pdftoolbar=true,
+pdfmenubar=true,
+debug=false,
+pagebackref=true
+]{hyperref}
+\DeclareGraphicsExtensions{ .pdf, .jpg, .tif}
+\else
+\usepackage[dvips]{graphicx}
+\DeclareGraphicsExtensions{ .eps, .jpg }
+\fi
+
+\usepackage{amsmath}
+\usepackage{enumitem}
+\usepackage[nolist]{acronym}
+\usepackage{memhfixc}
+\usepackage{xspace}
+\usepackage{prettyref}
+\usepackage{lmodern}
+\usepackage[T1]{fontenc}
+\usepackage{babel}
+\usepackage{tikz}
+
+\newrefformat{eq}{\textup{(\ref{#1})}}
+\newrefformat{cla}{claim \ref{#1}}
+\newrefformat{tab}{Table \ref{#1}}
+\newrefformat{fig}{\figurename \ \textbf{\ref{#1}}}
+
+\newcommand{\patentTitlePage}{%
+
+\ifx\assigneeName\undefined
+\global\edef\assigneeName{~}
+\global\edef\confidentialAssignee{~}
+\else
+\global\edef\confidentialAssignee{%
+Confidential Property of \assigneeName}
+\fi
+\ifx\assigneeAddress\undefined
+\global\edef\assigneeAddress{~}
+\fi
+\ifx\assigneeCity\undefined
+\global\edef\assigneeCity{~}
+\fi
+\ifx\assigneePhone\undefined
+\global\edef\assigneePhone{~}
+\fi
+\ifx\patentNumber\undefined
+\global\edef\patentNumber{~}
+\fi
+\ifx\patentLawyerName\undefined
+\global\edef\patentLawyerName{~}
+\fi
+\ifx\patentLawyerNumber\undefined
+\global\edef\patentLawyerNumber{~}
+\fi
+\ifx\patentLawyerPhone\undefined
+\global\edef\patentLawyerPhone{~}
+\fi
+\ifx\patentDocumentVersion\undefined
+\global\edef\patentDocumentVersion{0.0}
+\fi
+\ifx\thedate\undefined
+\global\edef\thedate{\today}
+\fi
+
+\ifPatentOfficeMode
+%patent office mode
+\pagestyle{title}
+\makeoddhead{myheadings}
+{}{}{\scriptsize{\patentNumber}}
+\makeevenhead{myheadings}
+{}{}{\scriptsize{\patentNumber}}
+\else
+%not patent office mode
+\pagestyle{title}
+\makeoddhead{myheadings}
+{\confidentialAssignee}
+{}
+{\scriptsize{Draft of \thedate\\version \patentDocumentVersion}}
+\makeevenhead{myheadings}
+{\confidentialAssignee}
+{}
+{\scriptsize{Draft of \thedate\\version \patentDocumentVersion}}
+\fi
+\begin{titlingpage}
+\aliaspagestyle{titlingpage}{myheadings}
+\begin{center}
+\textbf{APPLICATION FOR UNITED STATES LETTERS PATENT}
+\vskip 172 pt
+Title: \MakeUppercase{ \thetitle }
+\end{center}
+\vskip 172 pt
+\begin{flushleft} \begin{tabular}{rl} Inventors: &
+\theauthor \\
+& \inventorListName{1} \\
+& \inventorListName{2} \\
+& \inventorListName{3} \\
+& \inventorListName{4} \\
+& \inventorListName{5} \\
+& \inventorListName{6} \\
+& \inventorListName{7} \\
+& \inventorListName{8} \\
+\end{tabular}\par \end{flushleft}
+\begin{flushright}
+\tiny{
+\vskip 10 pt
+%\\[4\baselineskip]
+\patentLawyerName \\
+\patentLawyerNumber \\
+[2\baselineskip]
+\assigneeName \\
+\assigneeAddress \\
+\assigneeCity \\
+\assigneePhone
+}
+\end{flushright}
+\end{titlingpage}
+\parindent 10pt
+\DoubleSpacing
+}
+
+\renewcommand{\maketitle}{
+\patentTitlePage
+\patentStart
+}
+
+\def\figureName{FIG.}
+
+\def\etal{%
+\expandafter\ifx\csname inventorname 1\endcsname\relax
+\else
+~et~al.
+\fi
+}
+
+% use this command to put a comment in the margin
+\newcommand{\patentComment}[1]{
+\ifPatentOfficeMode
+%patent office mode
+\else
+%not patent office mode
+\begin{SingleSpace}
+\marginpar{\tiny\textcolor{red}{ \begin{flushleft} #1 \end{flushleft}}}
+\end{SingleSpace}
+\fi
+}
+
+\newcommand{\patentSection}[1]{
+\Needspace{8pc}
+\section[#1][]{}
+%\label{#2}
+\begin{center}
+\textbf{\underline{\MakeUppercase{{#1}}}}
+\end{center}
+}
+
+\newcommand{\patentParagraph}{
+\par\noindent
+\refstepcounter{parnum}[\textbf{%
+\ifnum \value{parnum} < 10 0\else\fi
+\ifnum \value{parnum} < 100 0\else\fi
+\ifnum \value{parnum} < 1000 0\else\fi
+\arabic{parnum}}]
+\indent}
+
+\newcommand{\patentStart}{
+\ifPatentOfficeMode
+%patent office mode
+\pagestyle{myheadings}
+\makeoddhead{myheadings}{}{}{\scriptsize{\patentNumber}}
+\makeevenhead{myheadings}{}{}{\scriptsize{\patentNumber}}
+\makeoddfoot{myheadings}{}{\thepage}{}
+\makeevenfoot{myheadings}{}{\thepage}{}
+\else
+%not patent office mode
+\pagestyle{myheadings}
+\makeoddhead{myheadings}
+{\confidentialAssignee}
+{}{\scriptsize{Draft of \thedate\\version \patentDocumentVersion}}
+\makeevenhead{myheadings}
+{\confidentialAssignee}
+{}{\scriptsize{Draft of \thedate\\version \patentDocumentVersion}}
+\makeoddfoot{myheadings}{\thepage}{}{\scshape{\tiny{\thetitle}}}
+\makeevenfoot{myheadings}{\scshape{\tiny{\thetitle}}}{}{\thepage}
+\fi
+
+\begin{center}\textbf{\MakeUppercase{ \thetitle }}\end{center}
+
+% don't show section numbers!
+\setcounter{secnumdepth}{-1}
+% let them go into the "TOC" (even though we won't print it) because
+% this allows the PDF file to contain the appropriate bookmarks
+\setcounter{tocdepth}{1}
+
+\setbeforesecskip{0pc}
+\setaftersecskip{0pc}
+\parskip=10pt
+
+% this is used to number paragraphs
+\newcounter{parnum}
+}
+
+
+\makeatletter
+\newcount\@inventornumber
+\@inventornumber=0
+\makeatother
+
+\makeatletter
+\def\otherInventor#1{
+\global\advance\@inventornumber by 1
+\expandafter\edef\csname inventorname \the\@inventornumber\endcsname{#1}}
+\makeatother
+
+\def\inventorListName#1{\csname inventorname #1\endcsname}
+
+% Claims are the only area where I still use labels, hence the
+% prettyref include.
+% \patentClaimsStart essentially begins the enumerate environment and
+% \patentClaimsEnd essentially ends it.
+% I'd like to remove this dependency someday and use the counter
+% mechanisms used elsewhere.
+
+% Inside, a claim is begin with \beginClaim which labels it and starts
+% an \item.
+% Claims are referenced with \claimRef
+\newcommand{\beginClaim}[1]{\item \label{cla:#1}}
+\newcommand{\claimRef}[1]{claim \ref{cla:#1}}
+
+\newcommand{\WhatIsClaimed}{What is claimed:}
+
+\newcommand{\patentClaimsStart}{
+\newpage
+\section[Claims][]{}
+\parskip=0pt
+\WhatIsClaimed
+\begin{enumerate}
+}
+
+\newcommand{\patentClaimsEnd}{
+\end{enumerate}
+\newpage
+}
+
+%I'm not sure what this is but I'm afraid to remove it
+\newcommand{\putfigcaption}{}
+
+% Patent drawings have a special header that numbers the drawing pages
+\newcommand{\patentDrawingsStart}{
+\cleartooddpage
+%\newpage
+\ifPatentOfficeMode
+%patent office mode
+\setcounter{page}{1}
+\pagestyle{myheadings}
+\makeoddhead{myheadings}{}{
+\tiny{\thetitle} \\
+\tiny{\theauthor\etal} \\
+\tiny{\patentNumber} \\
+\tiny{\patentLawyerName\ \patentLawyerPhone}\\[.1in]
+\tiny{\thepage/\thelastpage}
+}{}
+\makeevenhead{myheadings}{}{
+\tiny{\thetitle} \\
+\tiny{\theauthor\etal} \\
+\tiny{\patentNumber} \\
+\tiny{\patentLawyerName\ \patentLawyerPhone}\\[.1in]
+\tiny{\thepage/\thelastpage}
+}{}
+\makeoddfoot{myheadings}{}{}{}
+\makeevenfoot{myheadings}{}{}{}
+\else
+%not patent office mode
+\pagestyle{myheadings}
+\makeoddhead{myheadings}
+{\confidentialAssignee}
+{}
+{\scriptsize{Draft of \thedate\\version \patentDocumentVersion}}
+\makeevenhead{myheadings}
+{\confidentialAssignee}
+{}
+{\scriptsize{Draft of \thedate\\version \patentDocumentVersion}}
+\makeoddfoot{myheadings}{\thepage}{}{\scshape{\tiny{\thetitle}}}
+\makeevenfoot{myheadings}{\scshape{\tiny{\thetitle}}}{}{\thepage}
+\fi
+
+\section[Drawings][]{}
+\begin{SingleSpace}
+}
+
+\newcommand{\patentDrawingsEnd}{
+\end{SingleSpace}
+%\newpage
+\clearpage
+}
+
+\makeatletter
+\newcount\@annotationnumber
+\@annotationnumber=0
+\makeatother
+
+\makeatletter
+\newcount\@annotationfigurenumber
+\@annotationfigurenumber=0
+\makeatother
+
+\makeatletter
+\def\advanceannotationfigurenumber{
+\global\advance\@annotationfigurenumber by 1}
+\makeatother
+
+\makeatletter
+\def\setannotationnumber#1{%
+\global\@annotationnumber=#1
+\global\advance\@annotationnumber by -1
+}
+\makeatother
+
+\def\annotationnextfigure{
+\global\advance\@annotationfigurenumber by 1}
+
+\makeatletter
+\def\setannotationfigurenumber#1{%
+\global\@annotationfigurenumber=#1
+}
+\makeatother
+
+\makeatletter
+\def\@newannotation#1{
+\expandafter\ifx\csname anonum#1 \endcsname\relax
+\global\advance\@annotationnumber by 1
+\expandafter\edef\csname anoele \the\@annotationnumber\endcsname{#1}
+\expandafter\edef\csname anonum#1 \endcsname{\the\@annotationnumber}
+\expandafter\edef\csname anofignum \the\@annotationnumber\endcsname{%
+\the\@annotationfigurenumber}
+\else\message{error: duplicate annotation #1}\fi}
+\makeatother
+
+\makeatletter
+\def\annotationDefinition{%
+\@ifnextchar[{\@annotationDefinitionmulti}{\@newannotation}}
+\def\@annotationDefinitionmulti[#1]#2{%
+\@newannotation{#2}\annotationName{#1}
+\@ifnextchar[{\@annotationDefinitionfull}{}}
+\def\@annotationDefinitionfull[#1]{\annotationDescription{#1}}
+\makeatother
+
+\makeatletter
+\def\annotationDescription#1{%
+\expandafter\ifx\csname anodesc \the\@annotationnumber\endcsname\relax
+\expandafter\def\csname anodesc \the\@annotationnumber\endcsname{#1}
+\else
+\message{error while assigning description ``#1'' to annotation variable
+``\annotationListVariableName{\the\@annotationnumber}''
+ - it was already defined as
+``\annotationListDescription{\the\@annotationnumber}''.}\fi}
+\makeatother
+
+\makeatletter
+\def\annotationName#1{%
+\expandafter\ifx\csname anotext \the\@annotationnumber\endcsname\relax
+\expandafter\def\csname anotext \the\@annotationnumber\endcsname{#1}
+\else
+\message{error while assigning text name ``#1'' to annotation variable
+``\annotationListVariableName{\the\@annotationnumber}''
+ - it was already defined as
+``\annotationListText{\the\@annotationnumber}''.}\fi}
+\makeatother
+
+\makeatletter
+\def\annotationReference#1{%
+[\thinspace\annotationNumberReference{#1}\thinspace]}
+\makeatother
+
+\def\annotationNameAndReference#1{%
+\annotationTextReference{#1}~\annotationReference{#1}}
+
+\def\annotationDescriptionreference#1{%
+\csname anodesc \annotationNumberReference{#1}\endcsname}
+
+\def\annotationTextReference#1{%
+\csname anotext \annotationNumberReference{#1}\endcsname}
+
+\def\annotationNumberReference#1{\csname anonum#1 \endcsname}
+
+\def\annotationNumberReferenceUnderlined#1{\underline{\csname anonum#1 \endcsname}}
+
+\def\annotationListVariableName#1{\csname anoele #1\endcsname}
+
+\def\annotationListText#1{\csname anotext #1\endcsname}
+
+\def\annotationListDescription#1{\csname anodesc #1\endcsname}
+
+\def\annotationListFigureNumber#1{\csname anofignum #1\endcsname}
+
+\def\annotationListFigureDescription#1{\csname anofigdesc #1\endcsname}
+
+\def\annotationListFigureExtension#1{\csname anofigext #1\endcsname}
+
+\def\annotationListFigureCaption#1{\csname anofigcap #1\endcsname}
+
+\def\annotationListFigureName#1{\csname anofigname #1\endcsname}
+
+\def\annotationListPrintFigure#1#2{
+\edef\testa{#1}\edef\testb{#2}\edef\testzero{0}
+\ifx\testb\testzero
+\figureName #1---\annotationListFigureName{#1}.%
+\annotationListFigureExtension{#1}%
+---\annotationListFigureDescription{#1}
+\par
+\else
+\ifx\testa\testb
+\else
+\figureName #1---\annotationListFigureName{#1}.%
+\annotationListFigureExtension{#1}%
+---\annotationListFigureDescription{#1}
+\par
+\fi\fi
+}
+
+\def\annotationListSectionName{\section*{Annotation List}}
+
+\makeatletter
+\def\printAnnotationList{{%
+\@annotationnumber=1
+\@annotationfigurenumber=0
+\expandafter\ifx\csname anoele \the\@annotationnumber\endcsname\relax
+\else
+\annotationListSectionName\par
+\loop
+\expandafter\ifx\csname anoele \the\@annotationnumber\endcsname\relax
+\else
+\leftskip = -10 pt
+\annotationListPrintFigure{%
+\annotationListFigureNumber{\the\@annotationnumber}}
+{\the\@annotationfigurenumber}
+\leftskip = 10 pt
+%\hangindent = 20 pt
+%\hangafter
+\par
+\@annotationfigurenumber=%
+\annotationListFigureNumber{\the\@annotationnumber}
+\the\@annotationnumber---%
+\annotationListVariableName{\the\@annotationnumber}---%
+\annotationListText{\the\@annotationnumber}---%
+\annotationListDescription{\the\@annotationnumber}
+\par
+\leftskip = -10 pt
+\advance\@annotationnumber by 1
+\repeat
+\fi
+}}
+\makeatother
+
+\def\annotationFigureListPrintFigure#1{
+\figureName ~#1 \annotationListFigureDescription{#1}}
+
+\def\annotationFigureListSectionName{%
+\section*{Brief Description of the Drawings}}
+\def\annotationFigureListPreamble{%
+For a more complete understanding of the invention,
+reference is made to the following description and accompanying
+drawings, in which:\par}
+
+\def\setFigureListNoRunOn{%
+\def\annotationFigureListLast{.}
+\def\annotationFigureListNextLast{.}
+\def\annotationFigureListOther{.}
+}
+
+\def\annotationFigureListLast{.}
+\def\annotationFigureListNextLast{; and}
+\def\annotationFigureListOther{;}
+
+\makeatletter
+\def\printAnnotationFigureList{{
+\@annotationfigurenumber=1
+\expandafter\ifx\csname anofigdesc \the\@annotationfigurenumber\endcsname\relax
+\else
+\annotationFigureListSectionName\par
+\annotationFigureListPreamble\par
+\loop
+\expandafter\ifx\csname anofigdesc \the\@annotationfigurenumber\endcsname\relax
+\else
+\annotationFigureListPrintFigure{\the\@annotationfigurenumber}%
+{\advance\@annotationfigurenumber by 1
+\expandafter\ifx\csname anofigdesc \the\@annotationfigurenumber\endcsname\relax
+\annotationFigureListLast\else{\advance\@annotationfigurenumber by 1
+\expandafter\ifx\csname anofigdesc \the\@annotationfigurenumber\endcsname\relax
+\annotationFigureListNextLast\else\annotationFigureListOther\par\fi}\fi}
+\advance\@annotationfigurenumber by 1
+\repeat
+\fi
+}}
+\makeatother
+
+\makeatletter
+\def\figureDescription#1{%
+\expandafter\ifx\csname anofigdesc \the\@annotationfigurenumber\endcsname\relax
+\expandafter\def\csname anofigdesc \the\@annotationfigurenumber\endcsname{#1}
+\else
+\message{error while assigning description ``#1'' to annotation figure number
+``\the\@annotationfigurenumber'' - it was already defined as
+``\annotationListFigureDescription{\the\@annotationfigurenumber}''.}\fi}
+\makeatother
+
+\makeatletter
+\def\figureExtension#1{%
+\expandafter\ifx\csname anofigext \the\@annotationfigurenumber\endcsname\relax
+\expandafter\def\csname anofigext \the\@annotationfigurenumber\endcsname{#1}
+\else
+\message{error while assigning extension ``#1'' to annotation figure number
+``\the\@annotationfigurenumber'' - it was already defined as
+``\annotationListFigureExtension{\the\@annotationfigurenumber}''.}\fi}
+\makeatother
+
+\makeatletter
+\def\figureCaption#1{%
+\expandafter\ifx\csname anofigcap \the\@annotationfigurenumber\endcsname\relax
+\expandafter\def\csname anofigcap \the\@annotationfigurenumber\endcsname{#1}
+\else
+\message{error while assigning caption ``#1'' to annotation figure number
+``\the\@annotationfigurenumber'' - it was already defined as
+``\annotationListFigureCaption{\the\@annotationfigurenumber}''.}\fi}
+\makeatother
+
+\makeatletter
+\def\figureClearPageAfter{%
+\expandafter\def\csname anofigcp \the\@annotationfigurenumber\endcsname{}}
+\makeatother
+
+\makeatletter
+\def\@newfigure#1{
+\expandafter\ifx\csname fignum#1 \endcsname\relax
+\global\advance\@annotationfigurenumber by 1
+\expandafter\edef\csname anofigname \the\@annotationfigurenumber\endcsname{#1}
+\expandafter\edef\csname fignum#1 \endcsname{\the\@annotationfigurenumber}
+\else\message{error: duplicate annotation #1}\fi}
+\makeatother
+
+\makeatletter
+\def\figureDefinition{\@ifnextchar[{\@figuredefinitionmulti}{\@newfigure}}
+\def\@figuredefinitionmulti[#1]#2{\@newfigure{#2}\figureDescription{#1}}
+\makeatother
+
+\makeatletter
+\def\figureReference#1{FIG.~\figurenumberreference{#1}}
+\makeatother
+
+\def\figurenumberreference#1{\csname fignum#1 \endcsname}
+
+\expandafter\def\csname showfigure pdf\endcsname #1#2#3{%
+\begin{figure}[!ht]
+\centering
+\includegraphics[]{#1.#2}\par
+\figureReference{#1}~~#3 \par
+\end{figure}
+}
+
+\expandafter\def\csname showfigure tpx\endcsname #1#2#3{%
+\begin{figure}[ht]
+\centering
+\input{"#1.tpx"}\par
+\figureReference{#1}~~#3 \par
+\end{figure}
+}
+
+\expandafter\def\csname showfigure tex\endcsname #1#2#3{%
+\begin{figure}[ht]
+\centering
+\input{"#1.tex"}\par
+\figureReference{#1}~~#3 \par
+\end{figure}
+}
+
+\expandafter\def\csname showfigure placeholder\endcsname #1#2#3{%
+\begin{figure}[ht]
+\centering
+no extension provided for file name #1.\par This will be
+used as a placeholder\par
+\figureReference{#1}~~#3 \par
+\end{figure}
+}
+
+\expandafter\def\csname showfigure unk\endcsname #1#2#3{%
+\begin{figure}[ht]
+\centering
+\includegraphics[]{#1.#2}\par
+\figureReference{#1}~~#3 \par
+\end{figure}
+}
+
+\makeatletter
+\def\figures{{%
+\@annotationfigurenumber=1
+\expandafter\ifx\csname anofigname \the\@annotationfigurenumber\endcsname\relax
+\else
+\figuresStart
+\loop
+\expandafter\ifx\csname anofigname \the\@annotationfigurenumber\endcsname\relax
+\else
+\expandafter\ifx\csname anofigext \the\@annotationfigurenumber\endcsname\relax
+\edef\figureextension{placeholder}
+\else
+\edef\figureextension{%
+\annotationListFigureExtension{\the\@annotationfigurenumber}}
+\fi
+\expandafter\ifx\csname showfigure \figureextension\endcsname\relax
+% this is an unknown figure extension
+\def\figureshower{\csname showfigure unk\endcsname}
+\else
+\def\figureshower{\csname showfigure \figureextension\endcsname}
+\fi
+\figureshower{\annotationListFigureName{\the\@annotationfigurenumber}}%
+{\figureextension}%
+{\annotationListFigureCaption{\the\@annotationfigurenumber}}
+\expandafter\ifx\csname anofigcp \the\@annotationfigurenumber\endcsname\relax
+\else
+\clearpage
+\fi
+\advance\@annotationfigurenumber by 1
+\repeat
+\figuresEnd
+\fi
+}}
+\makeatother
+
+\def\annotationFigureListSectionName{
+\patentSection{Brief Description of the Drawings}}
+
+\def\annotationListSectionName{\patentSection{Annotation List}}
+
+\def\annotationFigureListPreamble{
+\patentParagraph{For a more complete understanding of the invention,
+reference is made to the following description and accompanying
+drawings, in which:}}
+
+\def\patentDrawingDescriptions{\printAnnotationFigureList}
+
+\def\referencePatentFigure#1{\figureReference{#1}}
+\def\annotate#1{\annotationReference{#1}}
+\def\annotateWithName#1{\annotationNameAndReference{#1}}
+
+\def\annotationFigureListPrintFigure#1{
+\patentParagraph{\figureName ~#1 \annotationListFigureDescription{#1}}}
+
+\def\annotateNoBrackets#1{\annotationNumberReference{#1}}
+
+\def\figuresStart{\patentDrawingsStart}
+\def\figuresEnd{\patentDrawingsEnd}
+
+\def\patentDrawings{%
+\ifPatentOfficeMode
+\else
+\printAnnotationList
+\fi
+
+\figures
+}
+
+\endinput
+%%
+%% End of file `patent.cls'.
diff --git a/macros/latex/contrib/uspatent/tex/uspatent.layout b/macros/latex/contrib/uspatent/tex/uspatent.layout
new file mode 100644
index 0000000000..4cbaa3a764
--- /dev/null
+++ b/macros/latex/contrib/uspatent/tex/uspatent.layout
@@ -0,0 +1,634 @@
+#% Do not delete the line below; configure depends on this
+# \DeclareLaTeXClass[uspatent]{uspatent}
+# uspatent textclass definition file
+# Author: Peter J. Pupalaikis <pete_pope@hotmail.com>
+# Version 1.0
+
+Format 35
+Columns 1
+Sides 2
+SecNumDepth 1
+TocDepth 1
+DefaultStyle Standard
+PageStyle Headings
+Provides makeidx 1
+Provides framed 1
+Provides subscript 1
+# Memoir has support for line spacing, but uses different names from
+# what setspace.sty does.
+Provides SetSpace 1
+
+
+ClassOptions
+ FontSize 9|10|11|12|14|17
+ PageStyle empty|plain|headings|myheadings|ruled|Ruled|companion
+ Other oldfontcommands
+End
+
+
+Style Standard
+ Margin Static
+ LatexType Paragraph
+ LatexName dummy
+ ParIndent 0.4
+ ParSkip 0.4
+ Align Block
+ AlignPossible Block, Left, Right, Center
+ LabelType No_Label
+End
+
+
+Input stdinsets.inc
+Input stdlists.inc
+Input stdcounters.inc
+Input stdfloats.inc
+Input stdsections.inc
+Input stdstarsections.inc
+Input numreport.inc
+Input stdtitle.inc
+Input stdstruct.inc
+
+Input lyxmacros.inc
+Input stdlayouts.inc
+
+NoStyle Part
+NoStyle Chapter
+NoStyle Section
+NoStyle Subsection
+NoStyle Subsubsection
+NoStyle Subparagraph
+NoStyle Part*
+NoStyle Chapter*
+NoStyle Section*
+NoStyle Subsection*
+NoStyle Subsubsection*
+NoStyle Subparagraph*
+NoStyle LyX-Code
+NoStyle Quotation
+NoStyle Quote
+NoStyle Verse
+NoStyle Address
+NoStyle Abstract
+NoStyle Bibliography
+NoStyle Author
+NoStyle Right_Address
+
+Style Inventor
+ Margin Static
+ LatexType Command
+ Category FrontMatter
+ InTitle 1
+ LatexName inventor
+ LabelSep xxx
+ ParSkip 0.4
+ TopSep 1.3
+ BottomSep 0.7
+ ParSep 0.7
+ Align Center
+ LabelType No_Label
+ Font
+ Size Large
+ EndFont
+End
+
+Style PatentSection
+ Category section
+ Align center
+ LatexType Command
+ LatexName patentSection
+ Font
+ Series Bold
+ Shape SmallCaps
+ Misc underbar
+ Size Larger
+ EndFont
+ ParSep 0.4
+ TopSep 2
+End
+
+Style DrawingsDescriptionSection
+ Category Drawings
+ LatexType command
+ LatexName patentDrawingDescriptions
+ KeepEmpty 1
+ LabelType Static
+ LabelString "------- Brief Description of Drawings ------"
+ Align Right
+ Font
+ Series Bold
+ Shape SmallCaps
+ Color Blue
+ Size Tiny
+ EndFont
+End
+
+Style PatentParagraph
+ Category MainText
+ LatexType Command
+ LatexName patentParagraph
+ ParSep 0.4
+End
+
+Style AssigneeName
+ Category Information
+ LatexType Command
+ LatexName setAssigneeName
+ LabelType Static
+ LabelString "Assignee Name: "
+ Align right
+ Font
+ Series Bold
+ Color Green
+ Size Small
+ EndFont
+End
+
+Style AssigneeAddress
+ Category Information
+ LatexType Command
+ LatexName setAssigneeAddress
+ LabelType Static
+ LabelString "Assignee Address: "
+ Align right
+ Font
+ Series Bold
+ Color Green
+ Size Small
+ EndFont
+End
+
+Style AssigneeCity
+ Category Information
+ LatexType Command
+ LatexName setAssigneeCity
+ LabelType Static
+ LabelString "Assignee City: "
+ Align right
+ Font
+ Series Bold
+ Color Green
+ Size Small
+ EndFont
+End
+
+Style AssigneePhone
+ Category Information
+ LatexType Command
+ LatexName setAssigneePhone
+ LabelType Static
+ LabelString "Assignee Phone: "
+ Align right
+ Font
+ Series Bold
+ Color Green
+ Size Small
+ EndFont
+End
+
+Style DocketNumber
+ Category Information
+ LatexType Command
+ LatexName setDocketNumber
+ LabelType Static
+ LabelString "Docket Number: "
+ Align right
+ Font
+ Series Bold
+ Color Green
+ Size Small
+ EndFont
+End
+
+Style LawyerName
+ Category Information
+ LatexType Command
+ LatexName setLawyerName
+ LabelType Static
+ LabelString "Patent Lawyer Name: "
+ Align right
+ Font
+ Series Bold
+ Color Green
+ Size Small
+ EndFont
+End
+
+Style LawyerNumber
+ Category Information
+ LatexType Command
+ LatexName setLawyerNumber
+ LabelType Static
+ LabelString "Patent Lawyer Reg Number: "
+ Align right
+ Font
+ Series Bold
+ Color Green
+ Size Small
+ EndFont
+End
+
+Style LawyerPhone
+ Category Information
+ LatexType Command
+ LatexName setLawyerPhone
+ LabelType Static
+ LabelString "Patent Lawyer Phone: "
+ Align right
+ Font
+ Series Bold
+ Color Green
+ Size Small
+ EndFont
+End
+
+Style OtherInventor
+ Category Information
+ LatexType Command
+ LatexName setOtherInventor
+ KeepEmpty 0
+ LabelType Static
+ LabelString "Other Inventor: "
+ Align right
+ Font
+ Series Bold
+ Color Green
+ Size Small
+ EndFont
+End
+
+Style Version
+ Category Information
+ LatexType Command
+ LatexName setDocumentVersion
+ KeepEmpty 0
+ LabelType Static
+ LabelString "Version: "
+ Align right
+ Font
+ Series Bold
+ Color Green
+ Size Small
+ EndFont
+End
+
+Style FigureDefinition
+ Category Drawings
+ LatexType Command
+ LatexName figureDefinition
+ KeepEmpty 0
+ LabelType Static
+ LabelString "Figure Definition: "
+ Align right
+ Font
+ Series Bold
+ Color Green
+ Size Small
+ EndFont
+End
+
+Style FigureCaption
+ Category Drawings
+ LatexType Command
+ LatexName figureCaption
+ KeepEmpty 0
+ LabelType Static
+ LabelString "Figure Caption: "
+ Align right
+ Font
+ Color Green
+ Size Small
+ EndFont
+End
+
+Style FigureClearPageAfter
+ Category Drawings
+ LatexType Command
+ LatexName figureClearPageAfter
+ KeepEmpty 1
+ LabelType Static
+ LabelString "Figure Clear Page After"
+ Align right
+ Font
+ Color Green
+ Size Small
+ EndFont
+End
+
+Style FigureExtension
+ Category Drawings
+ LatexType Command
+ LatexName figureExtension
+ KeepEmpty 0
+ LabelType Static
+ LabelString "Figure Extension: "
+ Align right
+ Font
+ Color Green
+ Size Small
+ EndFont
+End
+
+Style FigureDescription
+ Category Drawings
+ LatexType Command
+ LatexName figureDescription
+ KeepEmpty 0
+ LabelType Static
+ LabelString "Figure Description: "
+ Align right
+ Font
+ Color Green
+ Size Small
+ EndFont
+End
+
+Style AnnotationDefinition
+ Category Drawings
+ LatexType Command
+ LatexName annotationDefinition
+ KeepEmpty 0
+ LabelType Static
+ LabelString "Annotation Definition: "
+ Align right
+ Font
+ Series Bold
+ Color Red
+ Size Small
+ EndFont
+End
+
+Style AnnotationDescription
+ Category Drawings
+ LatexType Command
+ LatexName annotationDescription
+ KeepEmpty 0
+ LabelType Static
+ LabelString "Annotation Description: "
+ Align right
+ Font
+ Color Red
+ Size Small
+ EndFont
+End
+
+Style AnnotationName
+ Category Drawings
+ LatexType Command
+ LatexName annotationName
+ KeepEmpty 0
+ LabelType Static
+ LabelString "Annotation Name: "
+ Align right
+ Font
+ Color Red
+ Size Small
+ EndFont
+End
+
+Style DraftMode
+ Category PrintingMode
+ LatexType command
+ LatexName setPrintingModeDraft
+ KeepEmpty 1
+ LabelType Static
+ LabelString "Printing Mode --- Draft"
+ Align right
+ Font
+ Series Bold
+ Color Green
+ Size Small
+ EndFont
+End
+
+Style ApplicationMode
+ Category PrintingMode
+ LatexType command
+ LatexName setPrintingModeApplication
+ KeepEmpty 1
+ LabelType Static
+ LabelString "Printing Mode --- Application"
+ Align right
+ Font
+ Series Bold
+ Color Green
+ Size Small
+ EndFont
+End
+
+Style ClaimsStart
+ Category Claims
+ LatexType command
+ LatexName patentClaimsStart
+ KeepEmpty 1
+ LabelType Static
+ LabelString "------- Start of Patent Claims ------"
+ Align Right
+ Font
+ Series Bold
+ Shape SmallCaps
+ Color Blue
+ Size Tiny
+ EndFont
+End
+
+Style ClaimsEnd
+ Category Claims
+ LatexType command
+ LatexName patentClaimsEnd
+ KeepEmpty 1
+ LabelType Static
+ LabelString "------- End of Patent Claims ------"
+ Align Right
+ Font
+ Series Bold
+ Shape SmallCaps
+ Color Blue
+ Size Tiny
+ EndFont
+End
+
+InsetLayout "Flex:ClaimReference"
+ LyXType custom
+ Decoration classic
+ LabelString ClaimRef
+ ContentAsLabel true
+ LatexName claimRef
+ LatexType command
+ MultiPar false
+ CustomPars false
+ ForcePlain true
+ PassThru true
+ FreeSpacing true
+ ForceLTR true
+ Font
+ Family Typewriter
+ Color Red
+ EndFont
+ LabelFont
+ Family Typewriter
+ Color Red
+ Size Small
+ EndFont
+ HTMLIsBlock false
+End
+
+Style Claim
+ Category Claims
+ LatexType command
+ LatexName beginClaim
+ Font
+ Series Bold
+ Color Blue
+ EndFont
+End
+
+Style DrawingsSection
+ Category Drawings
+ LatexType command
+ LatexName patentDrawings
+ KeepEmpty 1
+ LabelType Static
+ LabelString "------- Patent Drawings ------"
+ Align Right
+ Font
+ Series Bold
+ Shape SmallCaps
+ Color Blue
+ Size Tiny
+ EndFont
+End
+
+InsetLayout "Flex:FigureReference"
+ LyXType custom
+ Decoration classic
+ LabelString PatentFigure
+ ContentAsLabel true
+ LatexName referencePatentFigure
+ LatexType command
+ MultiPar false
+ CustomPars false
+ ForcePlain true
+ PassThru true
+ FreeSpacing true
+ ForceLTR true
+ Font
+ Family Typewriter
+ Color Blue
+ EndFont
+ LabelFont
+ Family Typewriter
+ Color Blue
+ Size Small
+ EndFont
+ HTMLIsBlock false
+End
+
+InsetLayout "Flex:Annotation"
+ LyXType custom
+ Decoration classic
+ LabelString Annotation
+ ContentAsLabel true
+ LatexName annotate
+ LatexType command
+ MultiPar false
+ CustomPars false
+ ForcePlain true
+ PassThru true
+ FreeSpacing true
+ ForceLTR true
+ Font
+ Family Typewriter
+ Color Green
+ EndFont
+ LabelFont
+ Family Typewriter
+ Color Green
+ Size Small
+ EndFont
+ HTMLIsBlock false
+End
+
+
+InsetLayout "Flex:PatentComment"
+ LyXType custom
+ Decoration classic
+ LabelString Comment
+ ContentAsLabel false
+ LatexName patentComment
+ LatexType command
+ MultiPar false
+ CustomPars false
+ ForcePlain true
+ PassThru true
+ FreeSpacing true
+ ForceLTR true
+ LabelFont
+ Family Typewriter
+ Color Yellow
+ Size Small
+ EndFont
+ HTMLIsBlock false
+End
+
+InsetLayout "Flex:Annotation+Name"
+ LyXType custom
+ Decoration classic
+ LabelString Annotation+Name
+ ContentAsLabel true
+ LatexName annotateWithName
+ LatexType command
+ MultiPar false
+ CustomPars false
+ ForcePlain true
+ PassThru true
+ FreeSpacing true
+ ForceLTR true
+ Font
+ Series Bold
+ Family Typewriter
+ Color Green
+ EndFont
+ LabelFont
+ Series Bold
+ Family Typewriter
+ Color Green
+ Size Small
+ EndFont
+ HTMLIsBlock false
+End
+
+
+InsetLayout "Flex:Acronym"
+ LyXType custom
+ Decoration classic
+ LabelString Acronym
+ ContentAsLabel true
+ LatexName ac
+ LatexType command
+ MultiPar false
+ CustomPars false
+ ForcePlain true
+ PassThru true
+ FreeSpacing true
+ ForceLTR true
+ HTMLIsBlock false
+End
+
+Float
+ Type figure
+ GuiName FIG.
+ Placement tbp
+ Extension lof
+ NumberWithin none
+ Style plain
+ ListName "List of Figures"
+ IsPredefined true
+ UsesFloatPkg false
+ ListCommand listoffigures
+ RefPrefix fig
+End
+
+
+
+
+