Re: Prawn::Errors::CannotFit (Prawn::Errors::CannotFit)

Posted by mojavelinux on
URL: https://discuss.asciidoctor.org/Prawn-Errors-CannotFit-Prawn-Errors-CannotFit-tp8180p8181.html

From the README

An inline image in a table cell will not force the column wider if the width of the image exceeds the width of the column; either reduce the image width using pdfwidth or increase the width of the column using cols; another solution is to convert the cell to an AsciiDoc table cell (see https://github.com/asciidoctor/asciidoctor-pdf/issues/830).

Best Regards,

-Dan

On Tue, Aug 18, 2020 at 1:20 AM sroth [via Asciidoctor :: Discussion] <[hidden email]> wrote:
I don't understand what to do!

if i put in the Document:
image::001_vde_0100-600_besichtigung_allgemein.svg[,500]
it does'nt work!
If i set
image::001_vde_0100-600_besichtigung_allgemein.svg[,200]
it works!?

Pleas tell me why and what to do.

asciidoctor-pdf et1_handout.adoc --trace
Traceback (most recent call last):
        69: from C:/Ruby26-x64/bin/asciidoctor-pdf:23:in `<main>'
        68: from C:/Ruby26-x64/bin/asciidoctor-pdf:23:in `load'
        67: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/asciidoctor-pdf-1.5.3/bin/asciidoctor-pdf:27:in `<top (required)>'
        66: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/asciidoctor-2.0.10/lib/asciidoctor/cli/invoker.rb:111:in `invoke!'
        65: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/asciidoctor-2.0.10/lib/asciidoctor/cli/invoker.rb:111:in `each'
        64: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/asciidoctor-2.0.10/lib/asciidoctor/cli/invoker.rb:128:in `block in invoke!'
        63: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/asciidoctor-2.0.10/lib/asciidoctor/convert.rb:183:in `convert_file'
        62: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/asciidoctor-2.0.10/lib/asciidoctor/convert.rb:183:in `open'
        61: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/asciidoctor-2.0.10/lib/asciidoctor/convert.rb:183:in `block in convert_file'
        60: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/asciidoctor-2.0.10/lib/asciidoctor/convert.rb:118:in `convert'
        59: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/asciidoctor-2.0.10/lib/asciidoctor/document.rb:951:in `convert'
        58: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/asciidoctor-pdf-1.5.3/lib/asciidoctor/pdf/converter.rb:138:in `convert'
        57: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/asciidoctor-pdf-1.5.3/lib/asciidoctor/pdf/converter.rb:214:in `convert_document'
        56: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/asciidoctor-pdf-1.5.3/lib/asciidoctor/pdf/converter.rb:596:in `indent_section'
        55: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/asciidoctor-pdf-1.5.3/lib/asciidoctor/pdf/converter.rb:267:in `block in convert_document'
        54: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/asciidoctor-pdf-1.5.3/lib/asciidoctor/pdf/converter.rb:155:in `traverse'
        53: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/asciidoctor-2.0.10/lib/asciidoctor/document.rb:1020:in `content'
        52: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/asciidoctor-2.0.10/lib/asciidoctor/abstract_block.rb:84:in `content'
        51: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/asciidoctor-2.0.10/lib/asciidoctor/abstract_block.rb:84:in `map'
        50: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/asciidoctor-2.0.10/lib/asciidoctor/abstract_block.rb:84:in `block in content'
        49: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/asciidoctor-2.0.10/lib/asciidoctor/abstract_block.rb:75:in `convert'
        48: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/asciidoctor-pdf-1.5.3/lib/asciidoctor/pdf/converter.rb:138:in `convert'
        47: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/asciidoctor-pdf-1.5.3/lib/asciidoctor/pdf/converter.rb:586:in `convert_section'
        46: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/asciidoctor-pdf-1.5.3/lib/asciidoctor/pdf/converter.rb:155:in `traverse'
        45: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/asciidoctor-2.0.10/lib/asciidoctor/abstract_block.rb:84:in `content'
        44: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/asciidoctor-2.0.10/lib/asciidoctor/abstract_block.rb:84:in `map'
        43: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/asciidoctor-2.0.10/lib/asciidoctor/abstract_block.rb:84:in `block in content'
        42: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/asciidoctor-2.0.10/lib/asciidoctor/abstract_block.rb:75:in `convert'
        41: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/asciidoctor-pdf-1.5.3/lib/asciidoctor/pdf/converter.rb:138:in `convert'
        40: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/asciidoctor-pdf-1.5.3/lib/asciidoctor/pdf/converter.rb:586:in `convert_section'
        39: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/asciidoctor-pdf-1.5.3/lib/asciidoctor/pdf/converter.rb:155:in `traverse'
        38: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/asciidoctor-2.0.10/lib/asciidoctor/abstract_block.rb:84:in `content'
        37: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/asciidoctor-2.0.10/lib/asciidoctor/abstract_block.rb:84:in `map'
        36: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/asciidoctor-2.0.10/lib/asciidoctor/abstract_block.rb:84:in `block in content'
        35: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/asciidoctor-2.0.10/lib/asciidoctor/abstract_block.rb:75:in `convert'
        34: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/asciidoctor-pdf-1.5.3/lib/asciidoctor/pdf/converter.rb:138:in `convert'
        33: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/asciidoctor-pdf-1.5.3/lib/asciidoctor/pdf/converter.rb:710:in `convert_paragraph'
        32: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/asciidoctor-pdf-1.5.3/lib/asciidoctor/pdf/converter.rb:2860:in `layout_prose'
        31: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/asciidoctor-pdf-1.5.3/lib/asciidoctor/pdf/converter.rb:3903:in `typeset_text'
        30: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/prawn-2.2.2/lib/prawn/text.rb:166:in `text'
        29: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/prawn-2.2.2/lib/prawn/text.rb:218:in `formatted_text'
        28: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/prawn-2.2.2/lib/prawn/text.rb:360:in `draw_remaining_formatted_text_on_new_pages'
        27: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/asciidoctor-pdf-1.5.3/lib/asciidoctor/pdf/ext/prawn/extensions.rb:376:in `fill_formatted_text_box'
        26: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/prawn-2.2.2/lib/prawn/text/formatted/box.rb:212:in `render'
        25: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/prawn-2.2.2/lib/prawn/font.rb:215:in `save_font'
        24: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/prawn-2.2.2/lib/prawn/text/formatted/box.rb:213:in `block in render'
        23: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/pdf-core-0.7.0/lib/pdf/core/text.rb:214:in `character_spacing'
        22: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/prawn-2.2.2/lib/prawn/text/formatted/box.rb:214:in `block (2 levels) in render'
        21: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/prawn-templates-0.1.2/lib/prawn/text.rb:19:in `text_rendering_mode'
        20: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/prawn-2.2.2/lib/prawn/text/formatted/box.rb:219:in `block (3 levels) in render'
        19: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/asciidoctor-pdf-1.5.3/lib/asciidoctor/pdf/ext/prawn/extensions.rb:265:in `font_size'
        18: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/prawn-2.2.2/lib/prawn/font.rb:101:in `font_size'
        17: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/prawn-2.2.2/lib/prawn/text/formatted/box.rb:226:in `block (4 levels) in render'
        16: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/asciidoctor-pdf-1.5.3/lib/asciidoctor/pdf/formatted_text/inline_image_arranger.rb:12:in `wrap'
        15: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/prawn-2.2.2/lib/prawn/text/formatted/wrap.rb:53:in `wrap'
        14: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/prawn-2.2.2/lib/prawn/text/formatted/line_wrap.rb:47:in `wrap_line'
        13: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/prawn-2.2.2/lib/prawn/text/formatted/line_wrap.rb:77:in `apply_font_settings_and_add_fragment_to_line'
        12: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/prawn-2.2.2/lib/prawn/text/formatted/arranger.rb:166:in `apply_font_settings'
        11: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/pdf-core-0.7.0/lib/pdf/core/text.rb:218:in `character_spacing'
        10: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/prawn-2.2.2/lib/prawn/text/formatted/arranger.rb:175:in `block in apply_font_settings'
         9: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/prawn-2.2.2/lib/prawn/text/formatted/arranger.rb:255:in `apply_font_size'
         8: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/asciidoctor-pdf-1.5.3/lib/asciidoctor/pdf/ext/prawn/extensions.rb:265:in `font_size'
         7: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/prawn-2.2.2/lib/prawn/font.rb:101:in `font_size'
         6: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/prawn-2.2.2/lib/prawn/text/formatted/arranger.rb:255:in `block in apply_font_size'
         5: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/prawn-2.2.2/lib/prawn/text/formatted/line_wrap.rb:78:in `block in apply_font_settings_and_add_fragment_to_line'
         4: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/prawn-2.2.2/lib/prawn/text/formatted/line_wrap.rb:93:in `add_fragment_to_line'
         3: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/prawn-2.2.2/lib/prawn/text/formatted/line_wrap.rb:93:in `each'
         2: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/prawn-2.2.2/lib/prawn/text/formatted/line_wrap.rb:113:in `block in add_fragment_to_line'
         1: from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/prawn-2.2.2/lib/prawn/text/formatted/line_wrap.rb:226:in `fragment_finished'
C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/prawn-2.2.2/lib/prawn/text/formatted/line_wrap.rb:243:in `update_output_based_on_last_fragment': Prawn::Errors::CannotFit (Prawn::Errors::CannotFit)



If you reply to this email, your message will be added to the discussion below:
https://discuss.asciidoctor.org/Prawn-Errors-CannotFit-Prawn-Errors-CannotFit-tp8180.html
To start a new topic under Asciidoctor :: Discussion, email [hidden email]
To unsubscribe from Asciidoctor :: Discussion, click here.
NAML


--
Dan Allen (he, him, his) | @mojavelinux | https://twitter.com/mojavelinux