|
Hmm seems like I should just be able to read into the package like a directory, no? And I guess I don't mind too much to waste the extra time allocating the UIImage during the save operation. Could be worse.
|
# ? Jul 10, 2020 21:00 |
|
|
# ? Jun 6, 2024 05:43 |
|
Is there a type wildcard for generics? I want to check if a view's concrete class is ModifiedContent<Image, *>. I tried with <Image, Any> as the type constraints but that didn't match when I passed in some Image("something).scaleEffect(number). I'm trying to figure out how tabView is able to tell whether to display the view you pass for the tab buttons even when it's been modified (so it wouldn't be an instance of Image anymore).
|
# ? Jul 10, 2020 22:20 |
|
Is it possible to set a file's icon from an app? I'm saving user documents, and would like each one's icon to use a screenshot of the doc (that is already part of the document). So, not a single icon, but each file gets its own?
|
# ? Jul 15, 2020 23:24 |
|
lord funk posted:Is it possible to set a file's icon from an app? I'm saving user documents, and would like each one's icon to use a screenshot of the doc (that is already part of the document). So, not a single icon, but each file gets its own? Maybe this method? I’ve never done this so I don’t know which ... limitations it has.
|
# ? Jul 16, 2020 09:41 |
|
Dog on Fire posted:Maybe this method? I’ve never done this so I don’t know which ... limitations it has. Ooh, I'll look into that, thanks. Searching for 'custom file icons xcode' gets a million links about app icons, not files.
|
# ? Jul 16, 2020 14:07 |
|
https://twitter.com/xenadu02/status/1283531972401180672?s=21 https://twitter.com/xenadu02/status/1283532318032883712?s=21 Hah. That’s a very suggestive req. I have a feeling I know exactly what it’s going for, having gone down that route.
|
# ? Jul 16, 2020 17:03 |
|
Doctor w-rw-rw- posted:Hah. That’s a very suggestive req. I have a feeling I know exactly what it’s going for, having gone down that route.
|
# ? Jul 17, 2020 14:11 |
|
Edit: Never mind it does work as you'd expect awesomeolion fucked around with this message at 03:07 on Jul 19, 2020 |
# ? Jul 19, 2020 02:53 |
|
Okay this gets me every time. Why does load(fromContents:type:) call in a UIDocument when you first create the document with save(to:for:completionHandler:)? It's like, you create this blank document, and then a second later it tries to load its contents? edit: hmmm nope maybe there is something going on in my document that's causing this edit 2: double nope, I am confused as hell. I made a blank test document class, and in my app it calls load(fromContents:type:) after save(to:for:completionHandler:). But in a new blank project, the same thing doesn't happen solution: okay figured it out. If the file already exists at the fileURL, and you call save(to: fileURL for: .forCreating), it will load the contents. But if it's actually a new file, it won't. lord funk fucked around with this message at 17:02 on Jul 19, 2020 |
# ? Jul 19, 2020 16:10 |
|
Finally got tired of SF Mono not having the U+203E 'overscore' character so I edited the font: Before: After:
|
# ? Jul 28, 2020 17:54 |
|
So it seems that macOS 10.15.6 has a new kernel memory leak in the sandbox extension, as described here https://www.macrumors.com/2020/07/27/vmware-confirms-macos-virtualization-bug-causes-crashes/ . This is really ruining my day/week/month. Any chance someone here knows someone that could escalate this internally for a quick fix? Edit: I downgraded to macOS 10.15.5 because 10.15.6 was unbearable. They don't make it easy to downgrade, good thing I managed to dig up a 10.15.5 installer somehow. CeciPipePasPipe fucked around with this message at 16:16 on Aug 1, 2020 |
# ? Jul 30, 2020 14:56 |
|
Has anyone used coremltools to generate a model? I'd really like for the resulting bounding boxes to be normalized the same standard way as other VNImageBasedRequest results are, however all that seems to be visible on the Python side is the scaled input image in pixels, nothing about the screen size or the original size of the input image, which would be necessary in order to normalize.
|
# ? Aug 6, 2020 13:47 |
|
CeciPipePasPipe posted:So it seems that macOS 10.15.6 has a new kernel memory leak in the sandbox extension, as described here https://www.macrumors.com/2020/07/27/vmware-confirms-macos-virtualization-bug-causes-crashes/ . This is really ruining my day/week/month. They didn't provide a feedback number so that makes it about 100x more difficult for anyone to figure out what issue they reported.
|
# ? Aug 7, 2020 00:24 |
|
brand engager posted:We're redoing our app's UI and swapping to swiftUI since most of the old UI code will be rewritten. Hope this isn't going to turn out to be a nightmare to code. We're still working on this lmao
|
# ? Aug 7, 2020 00:35 |
|
brand engager posted:We're still working on this lmao any pitfalls you can recommend avoiding? I'm re-doing one of our views in SwiftUI for our next iteration. I'm the lone iOS dev so I can't rewrite the whole thing before Black Friday(ecomm.)
|
# ? Aug 7, 2020 02:08 |
|
Can't really think of any right now. I've had to reimplement the model and viewmodel classes a few times for reasons not really related to the swiftUI framework, and I'm about to have to do it again.
|
# ? Aug 7, 2020 02:33 |
|
Is debounce broken in views? I'm trying to do something when a variable in the viewmodel changes. This works but seems to fire before the value has actually changed code:
code:
code:
code:
Edit: looks like the same thing happens with .delay, maybe these publisher modifiers just dont work inside views brand engager fucked around with this message at 18:53 on Aug 12, 2020 |
# ? Aug 12, 2020 18:43 |
|
objectWillChange notifying you before it’s changed is the correct behavior. Kinda mystifying why there’s no corresponding objectDidChange, but whatever.
|
# ? Aug 14, 2020 14:11 |
|
It was changed from didChange to willChange during the Xcode11 betas. https://twitter.com/luka_bernardi/status/1151633281982406656?s=21
|
# ? Aug 14, 2020 16:04 |
|
Would’ve been nice if they’d kept didChange, and added willChange for anyone who cares. Having to do it this way is awkward at best...
|
# ? Aug 15, 2020 03:26 |
|
Spent 2+ hours trying to figure out why my builds started hanging. if you have a class using @dynamicMemberLookup you might be able to reference variable names that don't exist in the code, and instead of failing the build just never finishes. That also broke syntax highlighting in xcode so I wasn't able to spot what the mistake was.
|
# ? Aug 19, 2020 02:57 |
|
In a similar vein I spent a lot of time trying to fix previews. https://twitter.com/dannypier/status/1190312160557068293 one god drat check box.
|
# ? Aug 19, 2020 15:05 |
|
KidDynamite posted:In a similar vein I spent a lot of time trying to fix previews. oh yeah that got me last week too Now I'm just not measuring code coverage
|
# ? Aug 20, 2020 19:01 |
|
Glimm posted:Now I'm just not measuring code coverage Same. Didn't even need to get an error!
|
# ? Aug 21, 2020 00:18 |
|
3D people, some advice. I would like to draw 'letterbox' black bars on the top and bottom of my scene. One way I could do this is just do another render pass, and draw the black boxes on top of the already rendered 3D scene. However, I think it would be better to simply stencil out the top and bottom. This would leave it black (yay!) and also skip any rendering underneath (performance!). And, I wouldn't have to load up another render encoder to draw the black bars (performance!). My question is: how do I draw directly on the depth texture / stencil texture? In Metal, they are the same texture (which confuses me... why does the stencil texture show up black in the inspector?). I could blit copy in from another texture, but I'm not really sure how to do that if I also clear the depth texture on load.
|
# ? Sep 1, 2020 17:59 |
|
They’re “together” because of legacy reasons (Depth24Stencil8 hardware formats), but people use 32-bit float depth buffers now with stencil existing in a separate texture and so it’s just done for convenience. Anyway, the stencil test happens at the rasterization stage, so instead try to use scissor rects or a smaller viewport, so that geometry in those parts of the screen will just get clipped instead (skipping rasterization entirely).
|
# ? Sep 2, 2020 01:48 |
|
Any guesses why an uppercase sigma is Xcode's Breakpoint navigator icon for a breakpoint? None of the mathy uses for Σ that I can think of seem to fit.
|
# ? Sep 2, 2020 20:46 |
|
Doc Block posted:They’re “together” because of legacy reasons (Depth24Stencil8 hardware formats), but people use 32-bit float depth buffers now with stencil existing in a separate texture and so it’s just done for convenience. 👍🏻👍🏻👍🏻 scissor rects is exactly what I needed.
|
# ? Sep 2, 2020 21:38 |
|
pokeyman posted:Any guesses why an uppercase sigma is Xcode's Breakpoint navigator icon for a breakpoint? None of the mathy uses for Σ that I can think of seem to fit. Google and Wikipedia are saying sigma symbol helps you remember symbolic breakpoint and also: quote:In linguistics, Σ represents the set of symbols that form an alphabet 🤷♂️ Maybe it's like "symbol for symbolic" and that's as much thought as they put into it. awesomeolion fucked around with this message at 03:09 on Sep 4, 2020 |
# ? Sep 4, 2020 03:02 |
|
awesomeolion posted:🤷♂️ Maybe it's like "symbol for symbolic" and that's as much thought as they put into it. This is it.
|
# ? Sep 4, 2020 06:51 |
|
Mystery solved!
|
# ? Sep 4, 2020 15:03 |
|
Anyone here have any success shipping a an app that's primarily a webview wrapper to the iOS App Store? I've got a little personal project - a social media web app for sharing songs with your friends and listening back to them through Spotify/Apple Music - that I'd like to make a native app for, but I don't really have the time to make iOS and Android versions of my app from scratch. I would be using several native features: native Spotify/Apple Music SDKs (instead of their JS equivalents), native share target for posting songs, and push notifications. Apple's guidelines for this have been more or less the same for the past few years, from what I can tell: quote:4.2 Minimum Functionality I like to think these new features would, uh, "elevate it" (god they really do use the most vague and obnoxious language for these guidelines huh), but I'm not sure what Apple reviewers would think. So, I'm curious if any of y'all have had any experience with shipping (or trying to ship) a mostly-webview app in the past couple years, and how that's gone. I guess I could build a mostly webview version for iOS and Android, get it out on Android since that's easy, and if it gets rejected by Apple, learn... React Native or some poo poo to build a cross-platform app?
|
# ? Sep 5, 2020 17:40 |
|
I'm not sure push notifications will be convincing as they're also available to websites. The other bits sound more convincing, but I dunno if it'll satisfy app review. You probably know this already, but you can add a bookmark to your home screen, and you get a bit more control there than you do in a browser. No push notifications though. Fundamentally, the Awful app scrapes a website and dumps it into a webview, but it seems to meet the bar set by app review. There's nothing wrong with using a webview to render 90% of the area of the screen. So what's the difference between Awful and simply pointing a webview at a url? No idea what app review's answer would be, but I bet you could get there without too much pain. One approach might be to pull components out of the webview. No idea what your site looks like, but maybe you pull the navigation menu out and use a proper tab bar controller, with each tab simply loading the relevant webpage (and then hide the navigation bits when you render the webpage). That's probably not enough on its own, so now maybe one of the tabs is a list that you could make into a proper table view. We're probably getting pretty close, and I'd send it off for review to see what happens. Do the same for Android and you've got two apps that are more than just a webview, but hopefully aren't a massive amount of work? And you've got the scaffolding in place if you wanna pull more out of the webview. I assume you can do the above in something like react native too, but I haven't tried.
|
# ? Sep 5, 2020 21:41 |
|
Does anyone know if Microsoft has quietly dropped the Xamarin cross platform stuff. Got asked to use it for an app that runs on android and ios, but it just isn't in there on Visual studio for mac anymore. Theres references online to installing it from the VS installer, but theres just nothing in there. Its still got the option to do libraries, but the ability to do cross platform apps seems to have been removed :/ Or somethings broken. edit: No, apparently not dropped. Just broken. Goddamn it xamarin Super useful error too: "The project could not be created". In the logs theres a stack trace about a null ref. Doesnt seem to be something I can fix. duck monster fucked around with this message at 07:53 on Sep 8, 2020 |
# ? Sep 8, 2020 07:04 |
|
All cross platform sucks, but Flutter is the least sucky imo.
|
# ? Sep 9, 2020 04:45 |
|
TheReverend posted:All cross platform sucks, but Flutter is the least sucky imo. I've recently shipped a hobby app with Flutter and while some aspects of it were great, others are still biting me. I'd generally just stick to native iOS but this app relies on a wider community so skipping Android would hurt the iOS users. Granted the problems I've had with it are around the Google Maps component (fundamental to this app) which is still in "developer preview", but it has been for 2+ years. I also found that one of the bugs my users reported after release had been raised on the Github issues (with a one line workaround in the plugin) last September and still hasn't been addressed officially. Aside from quite a lot of missing features, these bugs make it feel like they're not really in a rush to "mature" the framework. Overall it's great for doing quick UI development and hitting both platforms from a single codebase, but a nightmare when bugs crop up and only affect certain devices. Though I feel that's any kind of Android development in a nutshell.
|
# ? Sep 9, 2020 10:28 |
|
I realize i'm just getting started with Swift, so everything is going to have a learning curve, but i'll be damned if I can't wrap my head around using Codable to parse even moderately complicated/nested JSON.
|
# ? Sep 9, 2020 18:05 |
|
frogbs posted:I realize i'm just getting started with Swift, so everything is going to have a learning curve, but i'll be damned if I can't wrap my head around using Codable to parse even moderately complicated/nested JSON. Yeah good luck. I just went through this a few weeks ago, and was surprised at how difficult heterogenous arrays were to encode / decode.
|
# ? Sep 9, 2020 18:44 |
|
frogbs posted:I realize i'm just getting started with Swift, so everything is going to have a learning curve, but i'll be damned if I can't wrap my head around using Codable to parse even moderately complicated/nested JSON. This can be a big help for creating your data models lord funk posted:Yeah good luck. I just went through this a few weeks ago, and was surprised at how difficult heterogenous arrays were to encode / decode. Yeah I recently had to deal with an endpoint that spat out a bunch of different variations and it was a nightmare
|
# ? Sep 9, 2020 18:54 |
|
|
# ? Jun 6, 2024 05:43 |
|
101 posted:This can be a big help for creating your data models Thanks! I did try this already, and laughed heartily at how much code it spit out just to deal with what I thought was a pretty simple feed. For some reason Xcode throws warnings with the recommended 'use this to parse' stuff line, which I think could be because i'm still on Mojave? Either way, i'll figure it out. code:
|
# ? Sep 9, 2020 19:13 |