Search results for

“translate scheme”

6,658 results found

Post

Replies

Boosts

Views

Activity

Reply to SwiftUI - Drag and Drop - drags adjacent views
Did you solve your problem ?Full code:struct DayView: View { @GestureState var dragState = DragState.inactive @State var viewDragState = CGSize(width: 0, height: 120) var translationOffset: CGSize { return CGSize(width: 0, height: viewDragState.height + dragState.translation.height) } enum DragState { case inactive case dragging(translation: CGSize) var translation: CGSize { switch self { case .dragging(let translation): return translation default: return .zero } } } var body: some View { let dragGesture = DragGesture() .updating($dragState) { value, state, transaction in state = .dragging(translation: value.translation) } .onEnded { value in self.viewDragState.height += value.translation.height self.viewDragState.width += value.translation.width } return GeometryReader { geometry in ZStack(alignment: .top) { VStack(spacing: 0) { ForEach(0..<2) {_ in Text(X).frame( height: 60) Divider() } } Text(Meet with Test 2-4).frame(width: geometry.size.width, height: 60, a
Topic: UI Frameworks SubTopic: SwiftUI Tags:
Jan ’20
Reply to New NSSearchToolbarItem in Mac Catalyst
Good news for you! Today, iPadOS with catalyst automatically translates navigationItem.searchController to AppKit native NSSearchToolbarItem. (However, only automatic-translation support AppKit native component. It is not available with manual NSToolbar. Please check the wwdc session. https://developer.apple.com/videos/play/wwdc2022/10076/ A public sample project is here https://developer.apple.com/documentation/uikit/app_and_environment/supporting_desktop-class_features_in_your_ipad_app.
Topic: App & System Services SubTopic: General Tags:
Aug ’22
Reply to xcstringstool not producing all localisations
Hello, String Catalogs do not build source language strings when the state is new, which is the default when strings are extracted from code and not further translated or varied in that language. To ensure a particular string builds anyway, you can choose Mark as Reviewed from the context menu to change the state to Translated. You can learn more about String Catalogs here: https://developer.apple.com/videos/play/wwdc2023/10155
Feb ’25
Reply to Is there a way to convert the data from ARDepthData into something like meters or centimeters?
Looks like hexadecimal data? If that's the case, it could be translated using a hexadecimal to decimal converter. Could you try to measure an object you know the length of, translate the values to decimal and see if they match? If yes, then that could be a potential solution. Also, I think you can convert those values directly in Swift, following this StackOverflow post. - https://stackoverflow.com/questions/36966442/convert-between-decimal-binary-and-hexadecimal-in-swift Best, William
Topic: Spatial Computing SubTopic: ARKit Tags:
Apr ’21
Reply to draw vision barcodes
Thank you very much. Is any information about how to translate from vision bounding box cgrect to UIKit coordinate space in objective c? I didn't found any page with information. In the tutorial that you attach there are some function en swift that i can't translate to objective c. This one: let rectangles = boxesAndPayload.map { $0.box } .map { CGRect(origin: $0.origin.translateFromCoreImageToUIKitCoordinateSpace(using: image.size.height), size: $0.size) } Thank you for your time
Topic: Machine Learning & AI SubTopic: General Tags:
Nov ’21
Reply to AppleGlot (Glossary) Usage / Terms of Service (ToS) Question
I understand that AppleGlot isn't an ideal solution. It was just meant to be a starting point for my project and isn't intended to be a long term solution. I was just wondering if my project were to absorb the translations provided in AppleGlot and potentially serve those translations to other developers in a more user-friendly way, would I be breaching some usage / terms of service guidelines. Is there a way I could escalate the ticket to someone that might be able to answer the legality aspect?
Sep ’20
Reply to Command SwiftCompile failed with a nonzero exit code. in xocde 16 and 15 where as it was working fine in xcode 14.3
Can you try following code DispatchQueue.main.async { let serverLangValue = // Server return value let switchEnum = translate (serverLangValue) let text = en //(or any other language code) switch switchEnum { case ABC: break case QPR: break case translate (text): break //From Xcode 16 and 15 swift compiler are file to process this case whereas older was working fine default: break } } } }
Oct ’24
Reply to Xliff export and \n
Lo and behold today I tried Xcode's export/import for the first time and used Xliffie for the external translating. Very convenient but a lot of crashes in XLiffie and Xcode. I got around the n issue by putting those strings in their own strings file with a unique table name. I only had three. I used NSLocalizedString(fooEnglish, tableName fooTable, comment:fooComment). It seems that straight-out-of-the-box Xcode's export/import function ignores uniquely named strings files and only export/imports the Localizable.strings file along with the Storyboard files. This works for me in this case because I am translating into two languages that I happen to know. However, if I was sending this out for professional translation, it would be an additional chore and expense to deal with these exceptions.
Mar ’16
Reply to Overlay two videos using AVMutableComposition?
One difficulty I always run into is the order of the elementary transformations when one of them is translation, because then they're no longer commutative and the order matters. Apple isn't very clear about the order (there are equivalent pre- and post-multiplication forms of the transform arithmetic, and you need to know which you're doing). On top of that, there may be a invisible coordinate flip transform (depending on whether the y coordinates increase from the top or the bottom), as well as a possible origin translation due to the semantics of the video frame geometry.Try doing just a single translation (ignoring size and rotation) and see if you can get rational placement. If so, trying adding in a small second transform again, and see if it's clear how it interacts with the translation.It ain't fun.
Topic: Media Technologies SubTopic: Audio Tags:
Nov ’17
Reply to iOS 18 Translation API availability for UIKit
Hello and thanks for your question and interest in the Translation API. These APIs do only work from SwiftUI, but it's not necessary to rewrite your app if you're using UIKit or AppKit. You can use a UIHostingController in the spot where you want to trigger translation, and keep the rest of your app as-is. There's a bit more detail in this reply on another post: https://developer.apple.com/forums/thread/756837?answerId=791116022#791116022
Topic: UI Frameworks SubTopic: UIKit Tags:
Jul ’24
SchemeBuildError: Failed to build the scheme
I have an iOS app, and I am trying to add a companion WatchOS app. My iOS app depends on 2 libraries: GoogleMobileAds FirebaseAnalyticsWithoutAdIdSupport When I add a new target for WatchOS, the preview build starts to fail. I am not adding any libraries to WatchOS. The Google Ads and Firebase Analytics libs are only under the iOS target. I am unable to run the preview, I get an error when trying to build the watch scheme. The preview does not work. The build just crashes. I've included the error log below. But, here are the steps I've tried so far: Delete folders inside Derived Data Run a clean build (Cmd + Option + Shift + K) Delete scheme and create a new one Reset Package Cache Restart Xcode Restart Macbook But, it just does not work. I do not understand why the watchOS target is erroring for GoogleUserMessagingPlatform and GoogleMobileAdsTarget when those packages are not linked/used for the watchOS. SchemeBuildError: Failed to build the scheme “timerWatch Watch App” While buil
0
0
117
Apr ’25
Reply to SwiftUI - Drag and Drop - drags adjacent views
Did you solve your problem ?Full code:struct DayView: View { @GestureState var dragState = DragState.inactive @State var viewDragState = CGSize(width: 0, height: 120) var translationOffset: CGSize { return CGSize(width: 0, height: viewDragState.height + dragState.translation.height) } enum DragState { case inactive case dragging(translation: CGSize) var translation: CGSize { switch self { case .dragging(let translation): return translation default: return .zero } } } var body: some View { let dragGesture = DragGesture() .updating($dragState) { value, state, transaction in state = .dragging(translation: value.translation) } .onEnded { value in self.viewDragState.height += value.translation.height self.viewDragState.width += value.translation.width } return GeometryReader { geometry in ZStack(alignment: .top) { VStack(spacing: 0) { ForEach(0..<2) {_ in Text(X).frame( height: 60) Divider() } } Text(Meet with Test 2-4).frame(width: geometry.size.width, height: 60, a
Topic: UI Frameworks SubTopic: SwiftUI Tags:
Replies
Boosts
Views
Activity
Jan ’20
Reply to How to migrate Bots to a new server
FYI the page referenced is in Korean, and if you right click on the page in google chrome, you can choose 'translate to English'.
Replies
Boosts
Views
Activity
Jan ’21
Reply to New NSSearchToolbarItem in Mac Catalyst
Good news for you! Today, iPadOS with catalyst automatically translates navigationItem.searchController to AppKit native NSSearchToolbarItem. (However, only automatic-translation support AppKit native component. It is not available with manual NSToolbar. Please check the wwdc session. https://developer.apple.com/videos/play/wwdc2022/10076/ A public sample project is here https://developer.apple.com/documentation/uikit/app_and_environment/supporting_desktop-class_features_in_your_ipad_app.
Topic: App & System Services SubTopic: General Tags:
Replies
Boosts
Views
Activity
Aug ’22
Reply to xcstringstool not producing all localisations
Hello, String Catalogs do not build source language strings when the state is new, which is the default when strings are extracted from code and not further translated or varied in that language. To ensure a particular string builds anyway, you can choose Mark as Reviewed from the context menu to change the state to Translated. You can learn more about String Catalogs here: https://developer.apple.com/videos/play/wwdc2023/10155
Replies
Boosts
Views
Activity
Feb ’25
Reply to Is there a way to convert the data from ARDepthData into something like meters or centimeters?
Looks like hexadecimal data? If that's the case, it could be translated using a hexadecimal to decimal converter. Could you try to measure an object you know the length of, translate the values to decimal and see if they match? If yes, then that could be a potential solution. Also, I think you can convert those values directly in Swift, following this StackOverflow post. - https://stackoverflow.com/questions/36966442/convert-between-decimal-binary-and-hexadecimal-in-swift Best, William
Topic: Spatial Computing SubTopic: ARKit Tags:
Replies
Boosts
Views
Activity
Apr ’21
Reply to draw vision barcodes
Thank you very much. Is any information about how to translate from vision bounding box cgrect to UIKit coordinate space in objective c? I didn't found any page with information. In the tutorial that you attach there are some function en swift that i can't translate to objective c. This one: let rectangles = boxesAndPayload.map { $0.box } .map { CGRect(origin: $0.origin.translateFromCoreImageToUIKitCoordinateSpace(using: image.size.height), size: $0.size) } Thank you for your time
Topic: Machine Learning & AI SubTopic: General Tags:
Replies
Boosts
Views
Activity
Nov ’21
Reply to AppleGlot (Glossary) Usage / Terms of Service (ToS) Question
I understand that AppleGlot isn't an ideal solution. It was just meant to be a starting point for my project and isn't intended to be a long term solution. I was just wondering if my project were to absorb the translations provided in AppleGlot and potentially serve those translations to other developers in a more user-friendly way, would I be breaching some usage / terms of service guidelines. Is there a way I could escalate the ticket to someone that might be able to answer the legality aspect?
Replies
Boosts
Views
Activity
Sep ’20
Reply to Command SwiftCompile failed with a nonzero exit code. in xocde 16 and 15 where as it was working fine in xcode 14.3
Can you try following code DispatchQueue.main.async { let serverLangValue = // Server return value let switchEnum = translate (serverLangValue) let text = en //(or any other language code) switch switchEnum { case ABC: break case QPR: break case translate (text): break //From Xcode 16 and 15 swift compiler are file to process this case whereas older was working fine default: break } } } }
Replies
Boosts
Views
Activity
Oct ’24
Reply to About a method to validate sandbox in iOS App
Your question is difficult to understand. Perhaps try posting in your native language, or get someone to help you with the English translation.
Replies
Boosts
Views
Activity
Nov ’15
Reply to US prescription requirement for preordering Vision Pro?!
Apple requires a US prescription if you wear glasses. Isn't this just a matter of translating mm to inches, or something?
Topic: App & System Services SubTopic: Core OS Tags:
Replies
Boosts
Views
Activity
Jan ’24
Reply to Exception with AVFoundation when using Speech framework in background (sporadic behavior)
I come from Xamarin, and this thing helped me:(I guess you can 'translate' it to swift 🙂 )https://bugzilla.xamarin.com/show_bug.cgi?id=38551
Topic: App & System Services SubTopic: Core OS Tags:
Replies
Boosts
Views
Activity
Jun ’17
Reply to Xliff export and \n
Lo and behold today I tried Xcode's export/import for the first time and used Xliffie for the external translating. Very convenient but a lot of crashes in XLiffie and Xcode. I got around the n issue by putting those strings in their own strings file with a unique table name. I only had three. I used NSLocalizedString(fooEnglish, tableName fooTable, comment:fooComment). It seems that straight-out-of-the-box Xcode's export/import function ignores uniquely named strings files and only export/imports the Localizable.strings file along with the Storyboard files. This works for me in this case because I am translating into two languages that I happen to know. However, if I was sending this out for professional translation, it would be an additional chore and expense to deal with these exceptions.
Replies
Boosts
Views
Activity
Mar ’16
Reply to Overlay two videos using AVMutableComposition?
One difficulty I always run into is the order of the elementary transformations when one of them is translation, because then they're no longer commutative and the order matters. Apple isn't very clear about the order (there are equivalent pre- and post-multiplication forms of the transform arithmetic, and you need to know which you're doing). On top of that, there may be a invisible coordinate flip transform (depending on whether the y coordinates increase from the top or the bottom), as well as a possible origin translation due to the semantics of the video frame geometry.Try doing just a single translation (ignoring size and rotation) and see if you can get rational placement. If so, trying adding in a small second transform again, and see if it's clear how it interacts with the translation.It ain't fun.
Topic: Media Technologies SubTopic: Audio Tags:
Replies
Boosts
Views
Activity
Nov ’17
Reply to iOS 18 Translation API availability for UIKit
Hello and thanks for your question and interest in the Translation API. These APIs do only work from SwiftUI, but it's not necessary to rewrite your app if you're using UIKit or AppKit. You can use a UIHostingController in the spot where you want to trigger translation, and keep the rest of your app as-is. There's a bit more detail in this reply on another post: https://developer.apple.com/forums/thread/756837?answerId=791116022#791116022
Topic: UI Frameworks SubTopic: UIKit Tags:
Replies
Boosts
Views
Activity
Jul ’24
SchemeBuildError: Failed to build the scheme
I have an iOS app, and I am trying to add a companion WatchOS app. My iOS app depends on 2 libraries: GoogleMobileAds FirebaseAnalyticsWithoutAdIdSupport When I add a new target for WatchOS, the preview build starts to fail. I am not adding any libraries to WatchOS. The Google Ads and Firebase Analytics libs are only under the iOS target. I am unable to run the preview, I get an error when trying to build the watch scheme. The preview does not work. The build just crashes. I've included the error log below. But, here are the steps I've tried so far: Delete folders inside Derived Data Run a clean build (Cmd + Option + Shift + K) Delete scheme and create a new one Reset Package Cache Restart Xcode Restart Macbook But, it just does not work. I do not understand why the watchOS target is erroring for GoogleUserMessagingPlatform and GoogleMobileAdsTarget when those packages are not linked/used for the watchOS. SchemeBuildError: Failed to build the scheme “timerWatch Watch App” While buil
Replies
0
Boosts
0
Views
117
Activity
Apr ’25