@krzyzanowskim@mastodon.social
@krzyzanowskim@mastodon.social avatar

krzyzanowskim

@krzyzanowskim@mastodon.social

 unrelated. too young to die. I'm here for bugs. https://CryptoSwift.io, Founder https://swiftstudio.app 🛠 TextKit2 certified expert. Text editor implementer by day.

This profile is from a federated server and may be incomplete. Browse more on the original instance.

jsq, to random
@jsq@mastodon.social avatar

Does anyone have tips for getting Xcode's Instruments to... uh… simply work at all?

It can't seem to find the dSYMs.

Has anyone at Apple ever tried to use this program. 🙃

krzyzanowskim,
@krzyzanowskim@mastodon.social avatar

@jsq q: where is your DerivedData it must be accessible for spotlight

krzyzanowskim,
@krzyzanowskim@mastodon.social avatar

@jsq it's just "double check" for me. I used to have .noindex in deriveddata directory and it never worked due to that and I had to manually adjust the dSYM path. But Xcode being Xcode

dasdom, to random
@dasdom@chaos.social avatar

Switch control support in iOS is freaking amazing!

This video shows how I draw a colored triangle in the Notes app on iOS.

krzyzanowskim,
@krzyzanowskim@mastodon.social avatar

@dasdom what’s that

krzyzanowskim, to random
@krzyzanowskim@mastodon.social avatar

🤔 thought of the day: the UITextView/NSTextView is probably the worst way to use the TextKit 2 framework to the fullest. many artificial limits put on the API or internal assumptions.

krzyzanowskim,
@krzyzanowskim@mastodon.social avatar

starting with: it support (assume) one type of storage, and it's not easy to make it use custom storage, nor layout engine.

krzyzanowskim,
@krzyzanowskim@mastodon.social avatar

followed by the fact it distort the (nice) architecture design choice and makes an subclass of abstract NSTextElement unusable, mandating one particular subclass a base type: NSTextParagraph. That is solely on the implementation, not the actual TextKit design.

krzyzanowskim,
@krzyzanowskim@mastodon.social avatar

also the late hierarchical additions to NSTextElement (parent, childElements) is solely to support specific implementation details and in my opinion shouldn't be on that level of the model. Somebody added it as “a hack" to make things work

bigzaphod, to random
@bigzaphod@mastodon.social avatar

Is there an easy way to write a data file (like something internal in Application Support or something) that's encrypted or otherwise secured? I swear there was. Maybe not, though? CloudKit's CKRecord has the encryptedValues thing that makes it easy to do it in that context, but what about a local file?

krzyzanowskim,
@krzyzanowskim@mastodon.social avatar

@bigzaphod „easy”? 🤔 i don’t know. but you can use SecureEnclave to store keys and encrypt file with CryptoKit. not sure if that’s still in the „easy” category

krzyzanowskim, to random
@krzyzanowskim@mastodon.social avatar

serious: I think about "rewrite" an app, and whether I should use Swift 6 concurrency mode, or Rust UI bindings. and Rust way seems easier to ship. even tho I'm way more Swift experienced.

krzyzanowskim,
@krzyzanowskim@mastodon.social avatar

@ctietze my thinking now

  1. Rust UI binding is good (Cocoa). There is not much (or any) advantage to using Swift bindings or Rust bindings to the ObjC framework anyway.
  2. Rust library is huge = many things easier to deliver
  3. Swift feels like too much to fight with still unknown solutions (new isolation-related proposals in works)
mattiem, to random
@mattiem@mastodon.social avatar

Concurrency in Swift 6

SE-0421: Generalize effect polymorphism for AsyncSequence and AsyncIteratorProtocol

AsyncSequence is getting some long-awaited improvements. I'm excited for this one, and I also think it's cool because isolated parameters are involved.

https://www.massicotte.org/concurrency-swift-6-se-0421

krzyzanowskim,
@krzyzanowskim@mastodon.social avatar

@mattiem Polywhatism? 😂😂😂

mattiem, to random
@mattiem@mastodon.social avatar

Inspired by @Migueldeicaza , I was thinking, again, about what would be required to support a full IDE experience on an iPad. And the propects are grim.

LSP is just fundamentally incompatible with iOS. And even with spec changes (which I have roughly outlined) that could be hard justify, it would still require enormous work from each server implementation to support.

krzyzanowskim,
@krzyzanowskim@mastodon.social avatar

@cdf1982 @mattiem apple did that already with Swift Playground, it’s full featured Swift compiler. And no, we can’t do the same with Swift. But with other languages (some of them) it is possible to some extent.

krzyzanowskim,
@krzyzanowskim@mastodon.social avatar

@helge swift thing is not designed to stay in process. and then it’s running the code that is also impossible on ios (again, not technically)

krzyzanowskim,
@krzyzanowskim@mastodon.social avatar

@helge that’s also my take. I love my iPad but coding on iPad is pure pain (at least with tools I used). It is slightly better with external keyboard (regular one), but even then iOS makes it awkward

krzyzanowskim, to random
@krzyzanowskim@mastodon.social avatar

I fixed scrolling in STTextView 0.9.2. It bugged me for a while that it was broken (not broken-broken, but the scroller's total size was not indicative). After learning one or two new things about the TextKit 2 layout behavior, I hereby report that the scrolling experience is back to normal without disturbing the overall performance.

https://github.com/krzyzanowskim/STTextView

I know this is a niche content. But that's what I like to do to destress. and I have too much stress lately

video/mp4

krzyzanowskim, to random
@krzyzanowskim@mastodon.social avatar

I'm trying to find out why text layout takes 4s (TextKit2), that some editors makes in a fraction of second. then I see that NSTextLayoutFragment._layout takes all the credits, mostly thanks to private NSCoreTypesetter. Why the heck text layout is so slow in UIFoundation

krzyzanowskim,
@krzyzanowskim@mastodon.social avatar

I don’t want to come up with textlayout reimplementation. I don’t have will to do it

krzyzanowskim,
@krzyzanowskim@mastodon.social avatar

@dgoldsmith it is an 8mb random text file. Do you check other FB too?

krzyzanowskim,
@krzyzanowskim@mastodon.social avatar
krzyzanowskim,
@krzyzanowskim@mastodon.social avatar

@dgoldsmith also this https://mastodon.social/@krzyzanowskim/112412883964891223 tho I didn’t fill FB for that one yet.

krzyzanowskim,
@krzyzanowskim@mastodon.social avatar

@dgoldsmith FB13792619

krzyzanowskim, to random
@krzyzanowskim@mastodon.social avatar

NSTextLayoutManager.usageBoundsForTextContainer is 🍌 bananas. Neither correct nor correct.

there. I said it.

krzyzanowskim,
@krzyzanowskim@mastodon.social avatar

bad news is I can’t easily (performance wise) workaround it

krzyzanowskim,
@krzyzanowskim@mastodon.social avatar
krzyzanowskim,
@krzyzanowskim@mastodon.social avatar

@ctietze that is NSLayoutManager thing (tk1)

krzyzanowskim,
@krzyzanowskim@mastodon.social avatar

@ctietze it's not. it just still has bugs 😉))))

  • All
  • Subscribed
  • Moderated
  • Favorites
  • Leos
  • mdbf
  • Youngstown
  • ngwrru68w68
  • ethstaker
  • slotface
  • PowerRangers
  • hgfsjryuu7
  • khanakhh
  • kavyap
  • tsrsr
  • InstantRegret
  • DreamBathrooms
  • cubers
  • tester
  • magazineikmin
  • rosin
  • tacticalgear
  • thenastyranch
  • Durango
  • osvaldo12
  • vwfavf
  • modclub
  • everett
  • GTA5RPClips
  • cisconetworking
  • normalnudes
  • anitta
  • All magazines