diff --git a/src/ifcblenderexport/ifcdoc/compile.py b/src/ifcblenderexport/ifcdoc/compile.py
new file mode 100644
index 0000000000..c19fbd4e8d
--- /dev/null
+++ b/src/ifcblenderexport/ifcdoc/compile.py
@@ -0,0 +1,43 @@
+import xml.etree.ElementTree as ET
+import pystache
+import ntpath
+import os
+
+sheet_path = 'sheets/sheet1.svg'
+sheet_filename = ntpath.basename(sheet_path)
+sheet_name = sheet_filename[0:-4]
+
+# hardcoded for testing
+data = [
+ {'number': 'ASDF', 'revision': 'A'},
+ {},
+ {'no': '01', 'name': 'HOUSE', 'scale': '1:100'},
+ {},
+ {'no': '02', 'name': 'ELEVATION', 'scale': '1:100'},
+ {},
+ {'no': '03', 'name': 'PLAN', 'scale': '1:100'},
+ {},
+ {'no': '04', 'name': 'SECTION', 'scale': '1:100'},
+ ]
+tree = ET.parse(sheet_path)
+root = tree.getroot()
+embedded_svgs = root.findall('{http://www.w3.org/2000/svg}svg')
+n = 0
+for svg in embedded_svgs:
+ use = svg.findall('{http://www.w3.org/2000/svg}use')[0]
+ source = use.attrib.get('{http://www.w3.org/1999/xlink}href')
+ source_path = source.split('#')[0]
+ source_filename = ntpath.basename(source_path)
+ source_anchor = source.split('#')[1]
+ dest_filename = '{}-{}.svg'.format(source_filename[0:-4], n)
+ print(dest_filename)
+ os.makedirs('build/refs/{}/'.format(sheet_name), exist_ok=True)
+ with open('build/refs/{}/{}'.format(sheet_name, dest_filename), 'w') as out:
+ with open('sheets/{}'.format(source_path), 'r') as template:
+ out.write(pystache.render(template.read(), data[n]))
+ use.set('{http://www.w3.org/1999/xlink}href',
+ 'refs/{}/{}#{}'.format(sheet_name, dest_filename, source_anchor))
+ n += 1
+
+with open('build/{}'.format(sheet_filename), 'wb') as output:
+ tree.write(output)
diff --git a/src/ifcblenderexport/generate_section.py b/src/ifcblenderexport/ifcdoc/generate_section.py
similarity index 100%
rename from src/ifcblenderexport/generate_section.py
rename to src/ifcblenderexport/ifcdoc/generate_section.py
diff --git a/src/ifcblenderexport/ifcdoc/sheets/sheet1.svg b/src/ifcblenderexport/ifcdoc/sheets/sheet1.svg
new file mode 100644
index 0000000000..80815d7993
--- /dev/null
+++ b/src/ifcblenderexport/ifcdoc/sheets/sheet1.svg
@@ -0,0 +1,34 @@
+
+
diff --git a/src/ifcblenderexport/ifcdoc/styles/default.css b/src/ifcblenderexport/ifcdoc/styles/default.css
new file mode 100644
index 0000000000..bdd2f65bf1
--- /dev/null
+++ b/src/ifcblenderexport/ifcdoc/styles/default.css
@@ -0,0 +1,2 @@
+.cut {fill: black; stroke: black; stroke-linecap: 'round'; stroke-width: 0.3px; }
+.background { fill: white; stroke: black; stroke-linecap: 'round'; stroke-width: 0.05px; }
diff --git a/src/ifcblenderexport/ifcdoc/templates/titleblock.svg b/src/ifcblenderexport/ifcdoc/templates/titleblock.svg
new file mode 100644
index 0000000000..f97a4069d0
--- /dev/null
+++ b/src/ifcblenderexport/ifcdoc/templates/titleblock.svg
@@ -0,0 +1,3084 @@
+
+
+
+
+
+ image/svg+xml
+
+
+
+
+
+
+ /home/dion/Projects/IfcOpenShell/src/ifcblenderexport/titleblock.dxf - scale = 1.000000, origin = (0.000000, 0.000000), method = manual
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ DATE
+
+
+ REV. BY
+
+
+ REV. NO.
+
+
+ DESCRIPTION TO REVISION
+
+
+
+
+
+ CUSTOMER
+
+
+
+
+ REV.
+
+
+ REFERENCE TO:
+
+
+ DRG No.
+
+
+
+ SCALE
+
+
+ A1
+
+
+
+
+
+
+ PROJECT PORTION
+
+
+ CLIENT APPROVED
+
+
+ ENGINEER APPROVED
+
+
+ CHECKED PROPOSAL
+
+
+ APPROVED PROPOSAL
+
+
+
+ DRAWN BY:
+
+
+
+
+ PROJECT
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ DRAWING NUMBER?DRAWING
+
+
+ DRAWING REVISION?REV
+
+
+ REFERENCE DWG.REFERENCE
+
+
+ SCALE?SCALE
+
+
+ NAMENAME
+
+
+ CUSTOMER - 1CUSTOMER
+
+
+ CUSTOMER - 2CUSTOMER
+
+
+ PROJECT - 1PROJECT
+
+
+ PROJECT - 2PROJECT
+
+
+ PROJECT - 3PROJECT
+
+
+ PROJECT - 4PROJECT
+
+
+ PORTION DISC 1PORTION
+
+
+ PORTION DISC 2PORTION
+
+
+ REV. NO. ATEXT
+
+
+ REVISION DESCRIPTION:-TEXT
+
+
+ REVISED BY?TEXT
+
+
+ DATE OF REVISION?TEXT
+
+
+ REV. NO. BTEXT
+
+
+ REVISION DESCRIPTION:-TEXT
+
+
+ REVISED BY?TEXT
+
+
+ DATE OF REVISION?TEXT
+
+
+ REV. NO. CTEXT
+
+
+ REVISION DESCRIPTION:-TEXT
+
+
+ REVISED BY?TEXT
+
+
+ DATE OF REVISION?TEXT
+
+
+ REV. NO. DTEXT
+
+
+ REVISION DESCRIPTION:-TEXT
+
+
+ REVISED BY?TEXT
+
+
+ DATE OF REVISION?TEXT
+
+
+ REV. NO. ETEXT
+
+
+ REVISION DESCRIPTION:-TEXT
+
+
+ REVISED BY?TEXT
+
+
+ DATE OF REVISION?TEXT
+
+
+ REV. NO. FTEXT
+
+
+ REVISION DESCRIPTION:-TEXT
+
+
+ REVISED BY?TEXT
+
+
+ DATE OF REVISION?TEXT
+
+
+ REV. NO. GTEXT
+
+
+ REVISION DESCRIPTION:-TEXT
+
+
+ REVISED BY?TEXT
+
+
+ DATE OF REVISION?TEXT
+
+
+ REV. NO. HTEXT
+
+
+ REVISION DESCRIPTION:-TEXT
+
+
+ REVISED BY?TEXT
+
+
+ DATE OF REVISION?TEXT
+
+
+ REV. NO. JTEXT
+
+
+ REVISION DESCRIPTION:-TEXT
+
+
+ REVISED BY?TEXT
+
+
+ DATE OF REVISION?TEXT
+
+
+ REV. NO. KTEXT
+
+
+ REVISION DESCRIPTION:-TEXT
+
+
+ REVISED BY?TEXT
+
+
+ DATE OF REVISION?TEXT
+
+
+ REV. NO. LTEXT
+
+
+ REVISION DESCRIPTION:-TEXT
+
+
+ REVISED BY?TEXT
+
+
+ DATE OF REVISION?TEXT
+
+
+
+
+
+ DATE
+
+
+ REV. BY
+
+
+ REV. NO.
+
+
+ DESCRIPTION TO REVISION
+
+
+
+
+
+ CUSTOMER
+
+
+
+
+ REV.
+
+
+ REFERENCE TO:
+
+
+ DRG No.
+
+
+
+ SCALE
+
+
+ A1
+
+
+
+
+
+
+ PROJECT PORTION
+
+
+ CLIENT APPROVED
+
+
+ ENGINEER APPROVED
+
+
+ CHECKED PROPOSAL
+
+
+ APPROVED PROPOSAL
+
+
+
+ DRAWN BY:
+
+
+
+
+ PROJECT
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ This drawing has been prepared based on the following design criteria.
+
+ Falsework:Concrete Mass=kN/m³
+ Live Load=kN/m²
+ Max. Axial Load on Standard / Prop=kN
+ Max. Jack Thread Extension=mm (U.N.O)
+ {
+ Scaffolding:Max. Working Lifts=No.
+ Max. Working Lift Load=kg/m² (UDL)
+ Max. Axial Load on Standard=kN
+ {
+ Back Propping / Re-propping: As per the Concrete Design Engineer's instruction.
+
+
+
+
+
+
+
+
+
+
+
+
+
+ NOTES
+ {
+ 1) This drawing is the exclusive property of Form-Scaff, a division of Waco Africa (Pty) Limited. It is subject to recall by Form-Scaff and must not be reproduced or its contents divulged
+ to third parties without Form-Scaff's prior written permission having been obtained.
+ {
+ 2) This drawing has been prepared from information supplied to Form-Scaff by the user, and is subject to final approval by user. It is the user's responsibility to ensure that the information supplied
+ to Form-Scaff has been correctly interpreted by Form-Scaff and that all dimensions and details shown are correct.
+ {
+ 3) Notwithstanding the provision of this drawing by Form-Scaff to the user, design responsibilityrests solely with the user.
+
+ 4) The user is referred to the provisions of the OHS Act, the Construction Regulations, and any relevant Codes of Practice, and the user confirms by accepting this drawing that it is familiar with the
+ provisions of the aforesaid statute, regulations and codes. It is further recommended that the user should have due regard to the provisions of British Standard BS5975.
+ {
+ 5) The user must ensure that "Good Practice" is adopted on site.
+ {
+ 6) This drawing has no status beyond that expressly denoted on the drawing. Where applicable, the user must ensure that any methods or specific instructions shown on this drawing are in
+ accordance with the user's requirements.
+
+ 7) The user must approach Form-Scaff for any advice or assistance in interpreting or complying with any of the above, or in the event of there being any ambiguity, contradiction, error or omission
+ apparent from this drawing or in respect of the specifications or use of any Form-Scaff equipment.
+
+
+
+ DRAWING NUMBER?DRAWING
+
+
+ DRAWING REVISION?REV
+
+
+ REFERENCE DWG.REFERENCE
+
+
+ SCALE?SCALE
+
+
+ NAMENAME
+
+
+ CUSTOMER - 1CUSTOMER
+
+
+ CUSTOMER - 2CUSTOMER
+
+
+ PROJECT - 1PROJECT
+
+
+ PROJECT - 2PROJECT
+
+
+ PROJECT - 3PROJECT
+
+
+ PROJECT - 4PROJECT
+
+
+ PORTION DISC 1PORTION
+
+
+ PORTION DISC 2PORTION
+
+
+ Falsework Concrete Mass?FALSEWORK
+
+
+ Falsework Live Load?FALSEWORK
+
+
+ Falsework Max. Axial load on Std / Prop?FALSEWORK
+
+
+ Falsework Max. Jack Thread Ext?FALSEWORK
+
+
+ Formwork Concrete pressure?FORMWORK
+
+
+ Formwork Max. Formwork Mass?FORMWORK
+
+
+ Formwork Max. Mass of Gang-formed unit?FORMWORK
+
+
+ Formwork Max. Rate of Pour?FORMWORK
+
+
+ Formwork Ambient Temperature?FORMWORK
+
+
+ Scaffolding Max. Working Lifts?SCAFFOLDING
+
+
+ Scaffolding Max. Working Lift Load?SCAFFOLDING
+
+
+ Scaffolding Max. Axial Load on Standard?SCAFFOLDING
+
+
+ REV. NO. ATEXT
+
+
+ REVISION DESCRIPTION:-TEXT
+
+
+ REVISED BY?TEXT
+
+
+ DATE OF REVISION?TEXT
+
+
+ REV. NO. BTEXT
+
+
+ REVISION DESCRIPTION:-TEXT
+
+
+ REVISED BY?TEXT
+
+
+ DATE OF REVISION?TEXT
+
+
+ REV. NO. CTEXT
+
+
+ REVISION DESCRIPTION:-TEXT
+
+
+ REVISED BY?TEXT
+
+
+ DATE OF REVISION?TEXT
+
+
+ REV. NO. DTEXT
+
+
+ REVISION DESCRIPTION:-TEXT
+
+
+ REVISED BY?TEXT
+
+
+ DATE OF REVISION?TEXT
+
+
+ REV. NO. ETEXT
+
+
+ REVISION DESCRIPTION:-TEXT
+
+
+ REVISED BY?TEXT
+
+
+ DATE OF REVISION?TEXT
+
+
+ REV. NO. FTEXT
+
+
+ REVISION DESCRIPTION:-TEXT
+
+
+ REVISED BY?TEXT
+
+
+ DATE OF REVISION?TEXT
+
+
+ REV. NO. GTEXT
+
+
+ REVISION DESCRIPTION:-TEXT
+
+
+ REVISED BY?TEXT
+
+
+ DATE OF REVISION?TEXT
+
+
+ REV. NO. HTEXT
+
+
+ REVISION DESCRIPTION:-TEXT
+
+
+ REVISED BY?TEXT
+
+
+ DATE OF REVISION?TEXT
+
+
+ REV. NO. JTEXT
+
+
+ REVISION DESCRIPTION:-TEXT
+
+
+ REVISED BY?TEXT
+
+
+ DATE OF REVISION?TEXT
+
+
+ REV. NO. KTEXT
+
+
+ REVISION DESCRIPTION:-TEXT
+
+
+ REVISED BY?TEXT
+
+
+ DATE OF REVISION?TEXT
+
+
+ REV. NO. LTEXT
+
+
+ REVISION DESCRIPTION:-TEXT
+
+
+ REVISED BY?TEXT
+
+
+ DATE OF REVISION?TEXT
+
+
+
+
+
+
+
+
+
+
+ REV. NO.
+
+
+
+
+
+
+
+
+
+
+
+
+ DESCRIPTION
+ AUTHOR
+ DATE
+
+
+ DRAWING NUMBER
+
+ REV
+ {{number}}
+ {{revision}}
+
+
+
+
+
+
+
diff --git a/src/ifcblenderexport/ifcdoc/templates/view-title.svg b/src/ifcblenderexport/ifcdoc/templates/view-title.svg
new file mode 100644
index 0000000000..a37dfbb5ed
--- /dev/null
+++ b/src/ifcblenderexport/ifcdoc/templates/view-title.svg
@@ -0,0 +1,71 @@
+
+
+
+
+
+
+ image/svg+xml
+
+
+
+
+
+
+
+
+ {{no}}
+ {{name}}
+ {{scale}}
+
+