Skip to content

Commit

Permalink
feat: chrome/m125
Browse files Browse the repository at this point in the history
  • Loading branch information
Brooooooklyn committed Apr 17, 2024
1 parent a54cd33 commit e58e642
Show file tree
Hide file tree
Showing 8 changed files with 16 additions and 8 deletions.
2 changes: 1 addition & 1 deletion README-zh.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# `skr canvas`

![CI](https://github.com/Brooooooklyn/canvas/workflows/CI/badge.svg)
![Skia Version](https://img.shields.io/badge/Skia-chrome%2Fm123-hotpink)
![Skia Version](https://img.shields.io/badge/Skia-chrome%2Fm125-hotpink)
[![install size](https://packagephobia.com/badge?p=@napi-rs/canvas)](https://packagephobia.com/result?p=@napi-rs/canvas)
[![Downloads](https://img.shields.io/npm/dm/@napi-rs/canvas.svg?sanitize=true)](https://npmcharts.com/compare/@napi-rs/canvas?minimal=true)

Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# `skr canvas`

![CI](https://github.com/Brooooooklyn/canvas/workflows/CI/badge.svg)
![Skia Version](https://img.shields.io/badge/Skia-chrome%2Fm123-hotpink)
![Skia Version](https://img.shields.io/badge/Skia-chrome%2Fm125-hotpink)
[![install size](https://packagephobia.com/badge?p=@napi-rs/canvas)](https://packagephobia.com/result?p=@napi-rs/canvas)
[![Downloads](https://img.shields.io/npm/dm/@napi-rs/canvas.svg?sanitize=true)](https://npmcharts.com/compare/@napi-rs/canvas?minimal=true)

Expand Down
2 changes: 1 addition & 1 deletion scripts/build-skia.js
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,6 @@ const GN_ARGS = [
`skia_use_gl=false`,
`skia_use_harfbuzz=true`,
`skia_use_icu=true`,
`skia_use_sfntly=false`,
`skia_use_libheif=true`,
`skia_use_libjpeg_turbo_decode=true`,
`skia_use_libjpeg_turbo_encode=true`,
Expand All @@ -83,6 +82,7 @@ const GN_ARGS = [
`skia_enable_fontmgr_custom_embedded=false`,
`skia_enable_fontmgr_custom_empty=true`,
`skia_enable_fontmgr_android=false`,
`skunicode_tests_enabled=false`
]

switch (PLATFORM_NAME) {
Expand Down
2 changes: 1 addition & 1 deletion scripts/release-skia-binary.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ if (TARGET && TARGET.startsWith('--target=')) {
TARGET_TRIPLE = TARGET.replace('--target=', '')
}

const LIB = ['skia', 'skparagraph', 'skshaper', 'svg', 'skunicode']
const LIB = ['skia', 'skparagraph', 'skshaper', 'svg', 'skunicode_core', 'skunicode_icu']
const ICU_DAT = 'icudtl.dat'

const CLIENT = new Octokit({
Expand Down
2 changes: 1 addition & 1 deletion skia
Submodule skia updated 1742 files
2 changes: 1 addition & 1 deletion skia-c/skia_c.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -441,7 +441,7 @@ extern "C"
paragraph_style.setTextStyle(text_style);
paragraph_style.setTextDirection(text_direction);
paragraph_style.setStrutStyle(struct_style);
ParagraphBuilderImpl builder(paragraph_style, font_collection, SkUnicode::Make());
ParagraphBuilderImpl builder(paragraph_style, font_collection, SkUnicodes::ICU::Make());
builder.addText(text, text_len);
auto paragraph = static_cast<ParagraphImpl *>(builder.Build().release());
paragraph->layout(MAX_LAYOUT_WIDTH);
Expand Down
1 change: 1 addition & 0 deletions skia-c/skia_c.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@
#include <modules/skparagraph/src/ParagraphBuilderImpl.h>
#include <modules/skparagraph/src/ParagraphImpl.h>
#include <modules/skparagraph/include/TypefaceFontProvider.h>
#include <modules/skunicode/include/SkUnicode_icu.h>
#include <modules/svg/include/SkSVGDOM.h>
#include <modules/svg/include/SkSVGSVG.h>
#include <modules/svg/include/SkSVGNode.h>
Expand Down
11 changes: 9 additions & 2 deletions src/sk.rs
Original file line number Diff line number Diff line change
Expand Up @@ -238,12 +238,19 @@ pub mod ffi {
)]
#[link(name = "skparagraph", kind = "static", cfg(target_os = "windows"))]
#[link(
name = "skunicode",
name = "skunicode_core",
kind = "static",
modifiers = "+bundle,+whole-archive",
cfg(not(target_os = "windows"))
)]
#[link(name = "skunicode", kind = "static", cfg(target_os = "windows"))]
#[link(name = "skunicode_core", kind = "static", cfg(target_os = "windows"))]
#[link(
name = "skunicode_icu",
kind = "static",
modifiers = "+bundle,+whole-archive",
cfg(not(target_os = "windows"))
)]
#[link(name = "skunicode_icu", kind = "static", cfg(target_os = "windows"))]
#[link(
name = "skia",
kind = "static",
Expand Down

0 comments on commit e58e642

Please sign in to comment.