html2odt 0.1.1 → 0.2.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 0eb97e63fc6a0d2d1f30044313a62d42466f98d2
4
- data.tar.gz: b280f0a0ae27a82aef74369ea3890f29697b904b
3
+ metadata.gz: d9acdd4dd439c892b26e76cdaa4357a22715d970
4
+ data.tar.gz: 1d93cf21cfe79188b4b11e51cdfd757174d65568
5
5
  SHA512:
6
- metadata.gz: 740f26a7b01026565d6ecd0537e29b9f28e88c13481872b41d0163dcbfaeca9d7f7e6c7b4f3748d295d4163402bcf0ca7a53eb33670619f3a1de10433c0b9953
7
- data.tar.gz: 6a691473ca9f0ca288703868ba798d13ae06b7dac4d1944d44f7d226d0ce4879e215bde2e1c7cf54794ea59d03a5813912d9ceb66ec708d67b537d9108d61caf
6
+ metadata.gz: 6ca018cee5cb3d8e74f2d94672f7de539199ededb3165f209daba36e16077c452779348e200f014a1aebfa57df86e140e7799ac523ff85132b43f342957e8ec0
7
+ data.tar.gz: 67f05f3ade7cf012d9aaf73623601f2331e492c4d70e1dc0334ee099315a3053ff7836c0bf60aee4c97fed95e86b7493664658378741b931a529fd93740a8678
data/CHANGELOG.md CHANGED
@@ -1,3 +1,8 @@
1
+ # v0.2.0 - 2016-05-24
2
+
3
+ Generating OpenDocument v1.1 instead of 1.2 to improve compatibility with
4
+ Microsoft Office 2010. Improving compatibility with OpenDocument standard.
5
+
1
6
  # v0.1.1 - 2016-05-23
2
7
 
3
8
  Being less strict about rubyzip version.
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- html2odt (0.1.1)
4
+ html2odt (0.2.0)
5
5
  dimensions (~> 1.3.0)
6
6
  nokogiri (~> 1.6.7.2)
7
7
  rubyzip (~> 1.0)
@@ -102,6 +102,8 @@ class Html2Odt::Document
102
102
  meta.xpath("dc:title").remove
103
103
  meta.add_child create_node(doc, "dc:title", title) if title
104
104
 
105
+ meta.xpath("meta:document-statistic").remove
106
+
105
107
  doc.to_xml
106
108
  end
107
109
  end
@@ -129,7 +131,12 @@ class Html2Odt::Document
129
131
  input_stream.sysread
130
132
  end
131
133
 
132
- output_stream.put_next_entry(entry.name)
134
+ if entry.name == "mimetype"
135
+ # mimetype may not be compressed
136
+ output_stream.put_next_entry(entry.name, nil, nil, Zlib::NO_COMPRESSION)
137
+ else
138
+ output_stream.put_next_entry(entry.name)
139
+ end
133
140
  output_stream.write data
134
141
  end
135
142
  end
@@ -1,3 +1,3 @@
1
1
  module Html2Odt
2
- VERSION = "0.1.1"
2
+ VERSION = "0.2.0"
3
3
  end
data/odt/template.odt CHANGED
Binary file
@@ -368,7 +368,7 @@
368
368
 
369
369
  <xsl:if test="count(//office:automatic-styles/style:style[@style:name = 'table-default']) = 0">
370
370
  <style:style style:name="table-default" style:family="table">
371
- <style:table-properties style:width="100%" table:align="margins"/>
371
+ <style:table-properties style:width="17cm" table:align="margins"/>
372
372
  </style:style>
373
373
  </xsl:if>
374
374
 
@@ -163,8 +163,7 @@
163
163
  style:border-line-width-bottom="0.002cm 0.035cm 0.002cm"
164
164
  fo:padding="0cm" fo:border-left="none" fo:border-right="none"
165
165
  fo:border-top="none" fo:border-bottom="0.04cm double #808080"
166
- text:number-lines="false" text:line-number="0"
167
- style:join-border="false"/>
166
+ text:number-lines="false" text:line-number="0"/>
168
167
  <style:text-properties fo:font-size="6pt"/>
169
168
  </style:style>
170
169
  </xsl:if>
@@ -333,8 +332,8 @@
333
332
  <style:style style:name="Definition_20_Term"
334
333
  style:display-name="Definition Term" style:family="paragraph"
335
334
  style:parent-style-name="Text_20_body" style:class="html">
336
- <style:text-properties fo:font-weight="bold"/>
337
335
  <style:paragraph-properties fo:margin-bottom="0cm"/>
336
+ <style:text-properties fo:font-weight="bold"/>
338
337
  </style:style>
339
338
  </xsl:if>
340
339
 
@@ -442,7 +441,6 @@
442
441
  style:horizontal-pos="right"
443
442
  style:horizontal-rel="paragraph"
444
443
  fo:background-color="transparent"
445
- style:background-transparency="100%"
446
444
  fo:padding="0.15cm"
447
445
  fo:border="0.002cm solid #000000"
448
446
  style:shadow="none">
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: html2odt
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Gregor Schmidt (Planio)
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-05-23 00:00:00.000000000 Z
11
+ date: 2016-05-24 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: dimensions