File: lines.rb

package info (click to toggle)
ruby-pdf-core 0.9.0-1
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, forky, sid, trixie
  • size: 356 kB
  • sloc: ruby: 1,978; makefile: 4
file content (12 lines) | stat: -rw-r--r-- 314 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
# frozen_string_literal: true

require_relative '../lib/pdf/core'

pdf = PDF::Core::Renderer.new(PDF::Core::DocumentState.new({}))

pdf.start_new_page
pdf.add_content("#{PDF::Core.real_params([100, 500])} m")
pdf.add_content("#{PDF::Core.real_params([300, 550])} l")
pdf.add_content('S')

pdf.render_file('x.pdf')