Skip to content

Commit

Permalink
Write WMode
Browse files Browse the repository at this point in the history
  • Loading branch information
laurmaedje committed Sep 30, 2024
1 parent b01b745 commit a349139
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/render/text.rs
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ use crate::Result;
use pdf_writer::types::{
CidFontType, FontFlags, SystemInfo, TextRenderingMode, UnicodeCmap,
};
use pdf_writer::writers::WMode;
use pdf_writer::{Chunk, Content, Filter, Finish, Name, Ref, Str};
use siphasher::sip128::{Hasher128, SipHasher13};
use std::collections::{BTreeMap, HashMap};
Expand Down Expand Up @@ -158,7 +159,7 @@ pub fn write_font(
font_descriptor.finish();

let cmap = create_cmap(glyph_set, glyph_remapper).ok_or(SubsetError(font.id))?;
chunk.cmap(cmap_ref, &cmap.finish());
chunk.cmap(cmap_ref, &cmap.finish()).writing_mode(WMode::Horizontal);

// Subset and write the font's bytes.
let data = subset_font(&font.face_data, font.face_index, glyph_remapper, font.id)?;
Expand Down

0 comments on commit a349139

Please sign in to comment.