- 26 Jul, 2023 1 commit
-
-
Elijah Semyonov authored
-
- 24 Jul, 2023 1 commit
-
-
Elijah Semyonov authored
* Move flush to `finally` block. * Prevent reentry when scene is invalidated within draw. * Revert "Move flush to `finally` block." This reverts commit 25b04b811c2425c27a04b7508dbd7de70b8ef735. * Prevent within frameListener as well.
-
- 21 Jul, 2023 2 commits
-
-
Alexey Tsvetkov authored
Resolves #766
-
Nikolai Rykunov authored
* Reuse Metal texture if size is not changed * Reuse bitmap storage and recreate it only when size is changed * Reuse ByteArrays if size is not changed
-
- 19 Jul, 2023 1 commit
-
-
Nikolai Rykunov authored
-
- 18 Jul, 2023 2 commits
-
-
Alexey Tsvetkov authored
* Fix dynamic framework support and fix binary compatibility of SkikoUIView This change configures Kotlin Gradle plugin to include a CInterop def file (https://kotlinlang.org/docs/native-c-interop.html) to fix linking a dynamic framework for iOS Also helps with https://youtrack.jetbrains.com/issue/KT-60399 (at least in some cases). Internal discussion https://jetbrains.slack.com/archives/G017NLN12D8/p1689594898607469 * CR fix: use flatmap
-
Elijah Semyonov authored
-
- 10 Jul, 2023 1 commit
-
-
Elijah Semyonov authored
* Add repro * Add ignore * Remove redundant retain * Add DisplayLinkThrottler implementation * Create Kotlin wrapper and JNI wrapper. * Integrate throttler into redrawer * Release CVDisplayLink in case of error * Fix wrong screen dictionary retrieval. * Remove temporary changes. * Rename test. * Add overcommitment prevention mechanism (#754) * Add overcommitment prevention mechanism * Replace hardcoded value with CAMetalLayer property * Update skiko/src/awtMain/objectiveC/macos/MetalContextHandler.mm Co-authored-by:
Igor Demin <igordmn@users.noreply.github.com> --------- Co-authored-by:
Igor Demin <igordmn@users.noreply.github.com> * Remove _displayLinkOk (#756) * Remove _displayLinkOk * Discussions * Fix build --------- Co-authored-by:
Igor Demin <igordmn@users.noreply.github.com>
-
- 07 Jul, 2023 1 commit
-
-
Elijah Semyonov authored
-
- 06 Jul, 2023 4 commits
-
-
dima.avdeev authored
Workaround was added in this PR: https://github.com/JetBrains/skiko/pull/682
-
dima.avdeev authored
-
dima.avdeev authored
Use workaround with Java sources. Because a platform Java type can be used as a platform type MotionEvent!
-
dima.avdeev authored
Rename interface to SkikoUITextInputTraits Also added missing functions from https://developer.apple.com/documentation/uikit/uitextinputtraits?language=objc
-
- 05 Jul, 2023 2 commits
-
-
dima.avdeev authored
Fixes after removing `fun onTouchEvent(events: Array<SkikoTouchEvent>)` in this PR: https://github.com/JetBrains/skiko/pull/725
-
dima.avdeev authored
-
- 04 Jul, 2023 1 commit
-
-
dima.avdeev authored
* iOS TextField add keyboard options * Simplify lateinit vars
-
- 30 Jun, 2023 2 commits
-
-
Oleksandr Karpovich authored
* Implement hostOs detection for web target * Refactor hostOs initialization in OsArch.js.kt Instead of using a lazy initialization, this change allows immediate initialization. * Deprecate incorrect enum OS.JS value in OsArch.kt Deprecation annotation has been added to JS enum in OsArch. This is done as 'JS' is not a valid host OS name. Added 'Unknown' enum for undefined or unknown cases to handle from now on. Consider using enum 'KotlinBackend' to detect JS. * Deprecate invalid Arch values and modify hostArch The Arch values 'JS' and 'WASM' were deprecated as they were found to be invalid. An 'Unknown' value was introduced to accommodate for unforeseen cases in the future. The 'hostArch' value under 'OsArch.js.kt' has been updated accordingly to use this new 'Unknown' value. * Add OS.Unknown to `when` expressions to make them exhaustive
-
Nikolai Rykunov authored
-
- 29 Jun, 2023 4 commits
-
-
Oleksandr Karpovich authored
-
-
Ivan Matkov authored
-
Ivan Matkov authored
-
- 28 Jun, 2023 1 commit
-
-
Nikolai Rykunov authored
--------- Co-authored-by:Igor Demin <igordmn@users.noreply.github.com>
-
- 26 Jun, 2023 4 commits
-
-
Igor Demin authored
* Refactoring from AWT Font PR Thanks, @rock3r, for refactorings! I extracted them from the AWT font PR (they were reverted in https://github.com/JetBrains/skiko/pull/639/commits/53f00c7d6be5ac0834ba4b4c3b9b4e3ea5cb0f10) - fix formatting - fix comments - split CI steps I am not sure about mikepenz/action-junit-report. Let's remove it for now (otherwise it should be investigated from functionality and security perspective) * Refactoring from AWT Font PR Thanks, @rock3r, for refactorings! I extracted them from the AWT font PR (they were reverted in https://github.com/JetBrains/skiko/pull/639/commits/53f00c7d6be5ac0834ba4b4c3b9b4e3ea5cb0f10) - fix formatting - fix comments - split CI steps I am not sure about mikepenz/action-junit-report. Let's remove it for now (otherwise it should be investigated from functionality and security perspective) Also, removed implementation("pl.pragmatists:JUnitParams:1.1.1"), as it isn't used.
-
Ivan Matkov authored
-
Ivan Matkov authored
-
Sebastiano Poggi authored
## Improve font loading and listing Available font listing doesn't rely anymore on discovering and loading font files from the disk. This is MUCH faster than the previous solution, which could take seconds on a performant machine. Besides, this greatly reduces memory usage as we're only holding the font family names list in memory, and cache items in memory lazily only once they are requested to speed up later lookups. Users can manually clear the memory cache, and register custom fonts (from files or resources). We now get the list of available font families directly from Skia, with some additional features such as adding entries for the system font on macOS (which is hidden by default). To note, the list of fonts available to Skia is not the same as available to AWT, for a number of reasons: 1. AWT adds logical fonts (e.g., `Dialog`) 2. AWT silently substitutes broken fonts 3. AWT lists the macOS system font, but under a weird name, `.AppleSystemUIFont`, whereas Skia doesn't 4. AWT and Skia don't use the same logic to list installed fonts on all platforms 5. AWT includes fonts embedded into the JVM automatically This makes things a bit more complicated, but if you _know_ the correct family name, everything works fine. While AWT silently substitutes invalid font family names with others, Skia will return `null` if it can't find a font. We follow the Skia approach, returning null if we can't match a font family name. ## Improve AWT `Font` conversion to Skiko `Typeface` On the JetBrains Runtime, the `Font.toSkikoTypefaceOrNull()` will be able to properly match an AWT `Font` to a Skiko `Typeface`, even on OSes other than macOS. If running on other JVMs, this returns `null`, as requested by @igordmn. This requirement is documented in the KDocs. The necessity to be on the JBR is due to the "regular" AWT implementations of `sun.font.Font2D` and `sun.funt.TrueTypeFont` being essentially broken: they read the wrong entry from the `name` table in TrueType fonts and use it as font family name. In the JBR, additional logic has been added to read the correct entry, the [_preferred family_](https://developer.apple.com/fonts/TrueType-Reference-Manual/RM06/Chap6name.html), and we can use this information to match with Skia font families, as Skia uses the correct _preferred family name_.
-
- 20 Jun, 2023 2 commits
-
-
Alexander Maryanovsky authored
Reimplement the Canvas transformation functions via the corresponding Skia functions, rather than by concatenating with a transformation matrix. (#724)
-
Alexander Maryanovsky authored
-
- 05 Jun, 2023 2 commits
-
-
Nikolai Rykunov authored
* Use naming constants instead of numbers for clear colors * Simplify clear colors logic and add comments
-
Ilya Ryzhenkov authored
Avoid sharing folders for build outputs to enable proper up-to-date checks and use of gradle 8.1.1 (#717)
-
- 30 May, 2023 1 commit
-
-
Oleksandr Karpovich authored
-
- 26 May, 2023 1 commit
-
-
Elijah Semyonov authored
* Make rundown rendering bandaid(or not) fix to avoid incorrect scheduling problem * Remove unneeded counter check. * Extract magic value. Document it. * Remove bandaid. * Make right scheduling. * Fix for path on double-dispatch during vsync-frame. * Change logging a bit. * Update doc * Update doc * Add comment on touchesCount, rephrase the body. * Replace control flow with `also` * Remove debug logs. * Refactor 2 booleans into single enum. * Simplify enum * Replace Unit with empty body in `when` expressions. * Replace comment style in function scopes. * Make DrawSchedulingState private. * Change comment style on private property. * Add rationale behind drawSchedulingState initial value.
-
- 17 May, 2023 2 commits
-
-
Elijah Semyonov authored
This reverts commit 85aef666.
-
Elijah Semyonov authored
Implement machinery for blocking draw dispatch before next vsync using synchronous wait on semaphore in native code. Implement mechanism to prevent Metal command buffers overcommitment.
-
- 16 May, 2023 2 commits
-
-
Martin Bonnin authored
Minor tweak to the README
-
Elijah Semyonov authored
* Add method to MetalRedrawer for obtaining current UIView to which metalLayer is attached. * Update caDisplayLink preferredFramesPerSecond when syncing metalLayer drawable size. * Update skiko/src/iosMain/kotlin/org/jetbrains/skiko/redrawer/MetalRedrawer.ios.kt Co-authored-by:
dima.avdeev <99798741+dima-avdeev-jb@users.noreply.github.com> --------- Co-authored-by:
dima.avdeev <99798741+dima-avdeev-jb@users.noreply.github.com>
-
- 10 May, 2023 2 commits
-
-
Elijah Semyonov authored
* Throw exception instead of force unwrapping Metal handles * Update skiko/src/macosMain/kotlin/org/jetbrains/skiko/redrawer/MetalRedrawer.macos.kt Co-authored-by:
Ivan Matkov <ivan.matkov@jetbrains.com> * Update based on review feedback * Remove redundant this * Remove unneeded imports --------- Co-authored-by:
Elijah Semyonov <elijah.semyonov@jetbrains.com> Co-authored-by:
Ivan Matkov <ivan.matkov@jetbrains.com>
-
Ivan Matkov authored
-
- 04 May, 2023 1 commit
-
-
Nikolai Rykunov authored
* [awt.metal] Extract MetalDevice interface into .h file * [awt.metal] Move context and renderTarget creation to ContextHandler ContextHandler shouldn't depend on redrawer, since redrawer depends on ContextHandler * [awt.metal] Use value class to hold MetalDevice pointer * [awt.metal] Add docs for MetalDevice * [awt.metal] Add simple docs for MetalRedrawer and MetalContextHandler * [awt.metal] Use null instead of artificial pointer to 0 --------- Co-authored-by:Ivan Matkov <ivan.matkov@jetbrains.com>
-