จัดทุกอย่างให้เป็นระเบียบอยู่เสมอด้วยคอลเล็กชัน
บันทึกและจัดหมวดหมู่เนื้อหาตามค่ากำหนดของคุณ
หมึก
สร้างแรงบันดาลใจให้แอปปากกาที่ดีที่สุด ลดอุปสรรคในการเริ่มต้นใช้งานสำหรับนักพัฒนาแอปเพื่อประสบการณ์การเขียนที่สวยงามและมีประสิทธิภาพสูง
อัปเดตล่าสุด |
รุ่นที่เสถียร |
รุ่นที่อาจได้รับการเผยแพร่ |
รุ่นเบต้า |
รุ่นอัลฟ่า |
13 สิงหาคม 2025 |
- |
- |
- |
1.0.0-alpha06 |
การประกาศทรัพยากร Dependency
หากต้องการเพิ่มทรัพยากร Dependency ใน Ink คุณต้องเพิ่มที่เก็บ Maven ของ Google ลงในโปรเจ็กต์
อ่านข้อมูลเพิ่มเติมได้ที่ที่เก็บ Maven ของ Google
เพิ่มการอ้างอิงสำหรับอาร์ติแฟกต์ที่คุณต้องการในไฟล์ build.gradle
สำหรับแอปหรือโมดูลของคุณ
Groovy
dependencies {
implementation "androidx.ink:ink-authoring:1.0.0-alpha06"
implementation "androidx.ink:ink-brush:1.0.0-alpha06"
implementation "androidx.ink:ink-geometry:1.0.0-alpha06"
implementation "androidx.ink:ink-nativeloader:1.0.0-alpha06"
implementation "androidx.ink:ink-rendering:1.0.0-alpha06"
implementation "androidx.ink:ink-strokes:1.0.0-alpha06"
}
Kotlin
dependencies {
implementation("androidx.ink:ink-authoring:1.0.0-alpha06")
implementation("androidx.ink:ink-brush:1.0.0-alpha06")
implementation("androidx.ink:ink-geometry:1.0.0-alpha06")
implementation("androidx.ink:ink-nativeloader:1.0.0-alpha06")
implementation("androidx.ink:ink-rendering:1.0.0-alpha06")
implementation("androidx.ink:ink-strokes:1.0.0-alpha06")
}
ดูข้อมูลเพิ่มเติมเกี่ยวกับการพึ่งพาได้ที่เพิ่มการพึ่งพาบิลด์
ความคิดเห็น
ความคิดเห็นของคุณช่วยเราปรับปรุง Jetpack ให้ดียิ่งขึ้น โปรดแจ้งให้เราทราบหากพบปัญหาใหม่หรือมี
ไอเดียในการปรับปรุงไลบรารีนี้ โปรดดูปัญหาที่มีอยู่
ในไลบรารีนี้ก่อนสร้างปัญหาใหม่ คุณสามารถโหวตปัญหาที่มีอยู่ได้โดย
คลิกปุ่มดาว
สร้างปัญหาใหม่
ดูข้อมูลเพิ่มเติมได้ในเอกสารประกอบของเครื่องมือติดตามปัญหา
ไม่มีบันทึกประจำรุ่นสำหรับอาร์ติแฟกต์นี้
รุ่น 1.0
เวอร์ชัน 1.0.0-alpha06
13 สิงหาคม 2025
androidx.ink:ink-*:1.0.0-alpha06
ได้รับการเผยแพร่แล้ว เวอร์ชัน 1.0.0-alpha06 มีการเปลี่ยนแปลงเหล่านี้
ฟีเจอร์ใหม่
- แปรงไฮไลต์อีโมจิในคลัง: ไฮไลต์ส่วนต่างๆ ของเอกสารด้วยอีโมจิที่คุณเลือก เพื่อเพิ่มลูกเล่นสนุกๆ และช่วยให้จัดระเบียบได้
- API ตัวช่วยเพิ่มเติมสำหรับรูปร่างดั้งเดิมของโมดูลเรขาคณิต
- ปรับปรุงความเข้ากันได้และประสิทธิภาพของอุปกรณ์
การเปลี่ยนแปลง API
- API ที่ง่ายขึ้นสำหรับ
InProgressStrokesView
, API เรขาคณิตของเส้นทาง, ไฮไลต์อีโมจิ, นำฟังก์ชันจากโรงงานออกจาก MutableParallelogram
เพื่อให้ใช้เมธอดเติมข้อมูลแทน, รองรับ Seed สำหรับลักษณะการทำงานของแปรงแบบสุ่ม (I38280)
การแก้ไขข้อบกพร่อง
- แก้ไขปัญหาด้านประสิทธิภาพและปัญหาความสอดคล้องของสีเมื่อเปียก/แห้ง (Ifcd1d)
เวอร์ชัน 1.0.0-alpha05
18 มิถุนายน 2025
androidx.ink:ink-*:1.0.0-alpha05
ได้รับการเผยแพร่แล้ว เวอร์ชัน 1.0.0-alpha05 มีการคอมมิตเหล่านี้
ฟีเจอร์ใหม่
- สร้างโมดูลความสามารถในการทำงานร่วมกันสำหรับโมดูลการเขียน แปรง และเรขาคณิต
การเปลี่ยนแปลง API
- โมดูลและการทำงานร่วมกันของ Compose ใหม่, API Cleanup (I0e464)
InProgressStroke.enqueueInputs/updateShape
วิธีการที่ส่งคืน kotlin.Result
จะถูกนำออก ลูกค้าควรใช้ enqueueInputsOrThrow
หรือ enqueueInputsOrIgnore
แทน เปลี่ยนชื่อ InProgressStroke.getNeedsUpdate
เป็น isUpdateNeeded
InProgressStroke.populateOutlinePosition
จะแสดงพารามิเตอร์เอาต์พุตเพื่อให้สามารถเชื่อมโยงการเรียกได้ ซึ่งสอดคล้องกับเมธอดอื่นๆ ใน Ink เราได้ย้ายอินเทอร์เฟซ TextureBitmapStore
จากโมดูลการแสดงผลไปยังโมดูลแปรง BoxAccumulator.populateFrom
จะใช้ Box ที่เปลี่ยนแปลงไม่ได้ซึ่งยอมรับค่า Null แทน BoxAccumulator
ที่เปลี่ยนแปลงได้ เพื่อให้เห็นได้ชัดเจนยิ่งขึ้นว่ามีการเปลี่ยนแปลงอะไรบ้าง ผู้เรียกใช้ควรเปลี่ยน boxAccumulator.add(other)
เป็น boxAccumulator.add(other.box)
BrushUtil.toBuilderWithAndroidColor/createBuilderWithAndroidColor
ถูกนำออกแล้ว โปรดใช้ setAndroidColor
ของ Brush.Builder
แทนหลังจากสร้าง (Ia7155)
- ตอนนี้พร็อพเพอร์ตี้
InProgressStrokesView.textureBitmapStore
ที่เคยเป็นเวอร์ชันทดลองเป็นแบบส่วนตัวแล้ว พร็อพเพอร์ตี้นี้ยังคงมีตัวช่วยเข้าถึงแบบสาธารณะ (I1d706)
การแก้ไขข้อบกพร่อง
- ปรับปรุงประสิทธิภาพสำหรับแปรงที่กำหนดเองซึ่งมีอนุภาคจำนวนมาก
เวอร์ชัน 1.0.0-alpha04
9 เมษายน 2025
androidx.ink:ink-*:1.0.0-alpha04
ได้รับการเผยแพร่แล้ว เวอร์ชัน 1.0.0-alpha04 มีการเปลี่ยนแปลงเหล่านี้
ฟีเจอร์ใหม่
- เปิดตัว API เวอร์ชันทดลองใหม่สำหรับออบเจ็กต์
BrushFamily
ที่กำหนดเอง ซึ่งช่วยให้ใช้แปรงใหม่ๆ เช่น ดินสอและเลเซอร์พอยน์เตอร์ได้ API อนุญาตให้โหลดแปรงที่กำหนดโดย Proto นี้ (I8809a)
เวอร์ชัน 1.0.0-alpha03
12 กุมภาพันธ์ 2025
androidx.ink:ink-*:1.0.0-alpha03
ได้รับการเผยแพร่แล้ว เวอร์ชัน 1.0.0-alpha03 มีคอมมิตเหล่านี้
ฟีเจอร์ใหม่
- ประหยัดขนาดดิสก์และเครือข่าย: การซีเรียลไลซ์ของ
StrokeInputBatch
ช่วยประหยัดโค้ดหลายบรรทัด และออบเจ็กต์ที่ได้มีขนาดเล็กมากเมื่อเทียบกับขนาดของลายเส้นที่จัดเก็บแบบเดิม (Ie898d)
- การเลือกแบบ Lasso: แปรงเส้นประเพื่อวาดเส้นการเลือก และฟังก์ชันเพื่อเปลี่ยนเส้นการเลือกเป็น
PartitionedMesh
สำหรับการค้นหาทางเรขาคณิต (Ia38a0)
เวอร์ชัน 1.0.0-alpha02
11 ธันวาคม 2024
androidx.ink:ink-*:1.0.0-alpha02
ได้รับการเผยแพร่แล้ว เวอร์ชัน 1.0.0-alpha02 มีการคอมมิตเหล่านี้
การเปลี่ยนแปลง API
การมีส่วนร่วมภายนอก
- เลิกใช้งาน
BuildCompat.isAtLeastV
ผู้โทรควรตรวจสอบ SDK_INT กับ 35 โดยตรงแทน (I294d1)
เวอร์ชัน 1.0.0-alpha01
2 ตุลาคม 2024
androidx.ink:ink-*:1.0.0-alpha01
ได้รับการเผยแพร่แล้ว เวอร์ชัน 1.0.0-alpha01 มีการเปลี่ยนแปลงเหล่านี้
ฟีเจอร์ใหม่
- ไลบรารีแบบแยกส่วนและกำหนดค่าได้ซึ่งช่วยให้สร้าง แสดงผล และจัดการเส้นหมึกที่สวยงามซึ่งเขียนในแอปพลิเคชันของคุณได้ง่าย
การเปลี่ยนแปลง API
โมดูลใหม่ที่จะช่วยให้นักพัฒนาแอปสร้างประสบการณ์การเขียนที่สมบูรณ์แบบ
- การเขียน: ใช้
InProgressStrokesView
เพื่อการแสดงผลลายเส้นแบบเรียลไทม์ที่มีประสิทธิภาพสูงและเวลาในการตอบสนองต่ำเมื่อได้รับอินพุต
- การแสดงผล: ใช้
CanvasStrokeRenderer
และ ViewStrokeRenderer
เพื่อวาดเส้นหมึกที่เสร็จสมบูรณ์เป็นส่วนหนึ่งของอินเทอร์เฟซผู้ใช้ของแอป
- เส้นขีด: ประเภทข้อมูลหลักที่ใช้สำหรับฟีเจอร์การเขียนด้วยหมึก
- พู่กัน: ข้อกำหนดที่กำหนดค่าได้เกี่ยวกับลักษณะและการทำงานของเส้นขีดเพื่อตอบสนองต่อข้อมูลจากผู้ใช้
- เรขาคณิต: การดำเนินการทางเรขาคณิต เช่น การตัดกันและความครอบคลุม เพื่อขับเคลื่อนเครื่องมือต่างๆ เช่น การเลือกและการลบ
ตัวอย่างเนื้อหาและโค้ดในหน้าเว็บนี้ขึ้นอยู่กับใบอนุญาตที่อธิบายไว้ในใบอนุญาตการใช้เนื้อหา Java และ OpenJDK เป็นเครื่องหมายการค้าหรือเครื่องหมายการค้าจดทะเบียนของ Oracle และ/หรือบริษัทในเครือ
อัปเดตล่าสุด 2025-08-13 UTC
[[["เข้าใจง่าย","easyToUnderstand","thumb-up"],["แก้ปัญหาของฉันได้","solvedMyProblem","thumb-up"],["อื่นๆ","otherUp","thumb-up"]],[["ไม่มีข้อมูลที่ฉันต้องการ","missingTheInformationINeed","thumb-down"],["ซับซ้อนเกินไป/มีหลายขั้นตอนมากเกินไป","tooComplicatedTooManySteps","thumb-down"],["ล้าสมัย","outOfDate","thumb-down"],["ปัญหาเกี่ยวกับการแปล","translationIssue","thumb-down"],["ตัวอย่าง/ปัญหาเกี่ยวกับโค้ด","samplesCodeIssue","thumb-down"],["อื่นๆ","otherDown","thumb-down"]],["อัปเดตล่าสุด 2025-08-13 UTC"],[],[],null,["# ink\n===\n\nAPI Reference \n[androidx.ink.authoring](/reference/kotlin/androidx/ink/authoring/package-summary) \n[androidx.ink.authoring.compose](/reference/kotlin/androidx/ink/authoring/compose/package-summary) \n[androidx.ink.brush](/reference/kotlin/androidx/ink/brush/package-summary) \n[androidx.ink.brush.compose](/reference/kotlin/androidx/ink/brush/compose/package-summary) \n[androidx.ink.geometry](/reference/kotlin/androidx/ink/geometry/package-summary) \n[androidx.ink.geometry.compose](/reference/kotlin/androidx/ink/geometry/compose/package-summary) \n[androidx.ink.android.canvas](/reference/kotlin/androidx/ink/rendering/android/canvas/package-summary) \n[androidx.ink.android.view](/reference/kotlin/androidx/ink/rendering/android/view/package-summary) \n[androidx.ink.strokes](/reference/kotlin/androidx/ink/strokes/package-summary) \nInspire best-in-class pen apps. Lower the developer barrier to entry for high performance, beautiful inking experiences. \n\n| Latest Update | Stable Release | Release Candidate | Beta Release | Alpha Release |\n|-----------------|----------------|-------------------|--------------|---------------------------------------------------------------|\n| August 13, 2025 | - | - | - | [1.0.0-alpha06](/jetpack/androidx/releases/ink#1.0.0-alpha06) |\n\nDeclaring dependencies\n----------------------\n\nTo add a dependency on Ink, you must add the Google Maven repository to your\nproject. Read [Google's Maven repository](/studio/build/dependencies#google-maven)\nfor more information.\n\nAdd the dependencies for the artifacts you need in the `build.gradle` file for\nyour app or module: \n\n### Groovy\n\n```groovy\ndependencies {\n \n implementation \"androidx.ink:ink-authoring:1.0.0-alpha06\"\n implementation \"androidx.ink:ink-brush:1.0.0-alpha06\"\n implementation \"androidx.ink:ink-geometry:1.0.0-alpha06\"\n implementation \"androidx.ink:ink-nativeloader:1.0.0-alpha06\"\n implementation \"androidx.ink:ink-rendering:1.0.0-alpha06\"\n implementation \"androidx.ink:ink-strokes:1.0.0-alpha06\"\n \n}\n```\n\n### Kotlin\n\n```kotlin\ndependencies {\n\n\n implementation(\"androidx.ink:ink-authoring:1.0.0-alpha06\")\n implementation(\"androidx.ink:ink-brush:1.0.0-alpha06\")\n implementation(\"androidx.ink:ink-geometry:1.0.0-alpha06\")\n implementation(\"androidx.ink:ink-nativeloader:1.0.0-alpha06\")\n implementation(\"androidx.ink:ink-rendering:1.0.0-alpha06\")\n implementation(\"androidx.ink:ink-strokes:1.0.0-alpha06\")\n}\n```\n\nFor more information about dependencies, see [Add build dependencies](/studio/build/dependencies).\n\nFeedback\n--------\n\nYour feedback helps make Jetpack better. Let us know if you discover new issues or have\nideas for improving this library. Please take a look at the\n[existing issues](https://issuetracker.google.com/issues?q=componentid:1662443%20status:open)\nin this library before you create a new one. You can add your vote to an existing issue by\nclicking the star button.\n\n[Create a new issue](https://issuetracker.google.com/issues/new?component=1662443&template=2055047)\n\nSee the [Issue Tracker documentation](https://developers.google.com/issue-tracker)\nfor more information.\n\nThere are no release notes for this artifact.\n\nVersion 1.0\n-----------\n\n### Version 1.0.0-alpha06\n\nAugust 13, 2025\n\n`androidx.ink:ink-*:1.0.0-alpha06` is released. Version 1.0.0-alpha06 contains [these commits](https://android.googlesource.com/platform/frameworks/support/+log/e8af6ab7417811bf386c52a59ab5d0b94d194eeb..c359e97fece91f3767a7d017e9def23c7caf1f53/ink).\n\n**New Features**\n\n- Emoji highlighter stock brush: Highlight parts of a document with any emoji you choose, to add a fun flair and help stay organized.\n- More helper APIs for geometry module primitive shapes\n- Improve device compatibility and performance\n\n**API Changes**\n\n- Simplified API for `InProgressStrokesView`, finish geometry APIs, emoji highlighter, remove factory functions from `MutableParallelogram` in favor of populate methods, support seed for randomized brush behaviors. ([I38280](https://android-review.googlesource.com/#/q/I38280146fca9a55b06d87a835670efdd012990e7))\n\n**Bug Fixes**\n\n- Fix a performance issue and a wet/dry color consistency issue. ([Ifcd1d](https://android-review.googlesource.com/#/q/Ifcd1da4081a01ba8165b4e8624219b1bd26bd248))\n\n### Version 1.0.0-alpha05\n\nJune 18, 2025\n\n`androidx.ink:ink-*:1.0.0-alpha05` is released. Version 1.0.0-alpha05 contains [these commits](https://android.googlesource.com/platform/frameworks/support/+log/4c37298a97c16270c139eb812ddadaba03e23a52..e8af6ab7417811bf386c52a59ab5d0b94d194eeb/ink).\n\n**New Features**\n\n- Compose interoperability modules for authoring, brush, and geometry modules\n\n**API Changes**\n\n- New Compose interoperability modules and APIs, API cleanup ([I0e464](https://android-review.googlesource.com/#/q/I0e4641822d568573fc8c7b3955a007a8ac9cd1c5))\n- `InProgressStroke.enqueueInputs/updateShape` methods which returned `kotlin.Result` are removed, clients should use e.g. `enqueueInputsOrThrow` or `enqueueInputsOrIgnore` instead. `InProgressStroke.getNeedsUpdate` is renamed to `isUpdateNeeded`. `InProgressStroke.populateOutlinePosition` now returns its output parameter to allow call chaining, consistent with other methods in Ink. The `TextureBitmapStore` interface is moved from the rendering module to the brush module. `BoxAccumulator.populateFrom` is made to take a nullable immutable Box instead of a mutable `BoxAccumulator`, to make it clearer what is mutated, callers should change `boxAccumulator.add(other)` to `boxAccumulator.add(other.box)`. `BrushUtil.toBuilderWithAndroidColor/createBuilderWithAndroidColor` are removed, use the `setAndroidColor` of `Brush.Builder` after constructing instead. ([Ia7155](https://android-review.googlesource.com/#/q/Ia7155560602b8319183aa12671d7f1d925873448))\n- Previously experimental property `InProgressStrokesView.textureBitmapStore` is now private. There are still public accessors for this property. ([I1d706](https://android-review.googlesource.com/#/q/I1d7064ff25c953066a4b43a6c30a4b3aa0b145d5))\n\n**Bug Fixes**\n\n- Improved performance for custom brushes containing many particles.\n\n### Version 1.0.0-alpha04\n\nApril 9, 2025\n\n`androidx.ink:ink-*:1.0.0-alpha04` is released. Version 1.0.0-alpha04 contains [these commits](https://android.googlesource.com/platform/frameworks/support/+log/24c00eb294d9cda579d8d6e48a29497fe0f8d3f7..4c37298a97c16270c139eb812ddadaba03e23a52/ink).\n\n**New Features**\n\n- Introduces new experimental APIs for custom `BrushFamily` objects, enabling new brushes like Pencil and Laser Pointer. The API allows for loading brushes defined by this proto. ([I8809a](https://android-review.googlesource.com/#/q/I8809a675a5527c1a7bc2f519e041a8af1ed693b3))\n\n### Version 1.0.0-alpha03\n\nFebruary 12, 2025\n\n`androidx.ink:ink-*:1.0.0-alpha03` is released. Version 1.0.0-alpha03 contains [these commits](https://android.googlesource.com/platform/frameworks/support/+log/46295bc0b75a16f452e8e0090e8de41073d4dbb6..24c00eb294d9cda579d8d6e48a29497fe0f8d3f7/ink).\n\n**New Features**\n\n- Disk and network size savings: Serialization of `StrokeInputBatch`, saving many lines of code, with the resulting objects a tiny fraction of the size of traditionally stored strokes. ([Ie898d](https://android-review.googlesource.com/#/q/Ie898d91e3c77eccbf26e9ee6d7f384a3a57b974f))\n- Lasso selection: dashed line brush to draw a selection stroke, and a function to turn the selection stroke into a `PartitionedMesh` for geometry queries. ([Ia38a0](https://android-review.googlesource.com/#/q/Ia38a0e3e7a2da344d978bdfd5b8db8210a753e74))\n\n### Version 1.0.0-alpha02\n\nDecember 11, 2024\n\n`androidx.ink:ink-*:1.0.0-alpha02` is released. Version 1.0.0-alpha02 contains [these commits](https://android.googlesource.com/platform/frameworks/support/+log/b6ae8d0a0e8cd803f7b84f30101eda1af4f1d6b6..46295bc0b75a16f452e8e0090e8de41073d4dbb6/ink).\n\n**API Changes**\n\n- Assorted bug fixes. ([I05dd8](https://android-review.googlesource.com/#/q/I05dd84cb83c29b6f8af876164c426fee57f6f932))\n\n**External Contribution**\n\n- Deprecate `BuildCompat.isAtLeastV`. Callers should check SDK_INT against 35 directly instead. ([I294d1](https://android-review.googlesource.com/#/q/I294d117a8fea924e7f1b739d52268a9a54be6db7))\n\n### Version 1.0.0-alpha01\n\nOctober 2, 2024\n\n`androidx.ink:ink-*:1.0.0-alpha01` is released. Version 1.0.0-alpha01 contains [these commits](https://android.googlesource.com/platform/frameworks/support/+log/b6ae8d0a0e8cd803f7b84f30101eda1af4f1d6b6/ink).\n\n**New Features**\n\n- A modular and configurable library to make it easy to create, render, and manipulate beautiful ink strokes authored in your application.\n\n**API Changes**\n\nNew modules to help developers build rich inking experiences:\n\n- Authoring: Use `InProgressStrokesView` for high-performance, low latency rendering of strokes in real time as inputs are received.\n- Rendering: Use `CanvasStrokeRenderer` and `ViewStrokeRenderer` to draw the finished ink strokes as part of an app's user interface.\n- Strokes: Core data types used for inking features.\n- Brush: Configurable specification of how strokes will look and act in response to user input.\n- Geometry: Geometric operations like intersection and coverage to power tools like selection and erasing."]]