Change the color of a focused element (Picker) SwiftUI - WatchOS
How can I change the focus color of a selected element in WatchOS7 with swiftUI. Here's my example below with a Picker whose focus color is green (the default one) but I want to change it to blue to be...
View ArticleCreate a done button for RxPickerViewAttributedStringAdapter
self.genderSource = RxPickerViewAttributedStringAdapter<[[DKProfileOption]]>.init(components:[]) { dataSource, pickerView, components inreturn 1} numberOfRowsInComponent: { [weak self]...
View ArticleHow to prevent interaction with .compact UIDatePicker until a password is...
I am using a UIDatePicker in my app to allow picking time:let startTimePicker = UIDatePicker()startTimePicker.addTarget.preferredDatePickerStyle = .compactstartTimePicker.addTarget.datePickerMode =...
View ArticleHow do I hide (or recolor) the default selection highlight in a UIPickerView...
What I’m trying to doI’m wrapping a custom UIKit UIPickerView in SwiftUI because I need:custom row height (56 pt)SwiftUI data bindingEverything works, except I still see the system‑gray selection...
View Articletwo uitextfield i want one to be disabled so it cannot be edited - SWIFT
I have two UITextField one is a normal textfield which requires text to be inputted. The other is connected to a UIPickerView. When i click the UITextField which is connected to the pickerView a cursor...
View ArticleUIPickerView best practice?
One short question: on a registration process I would like to ask the user to choose a value from a list of values.Is it the right way to use a view Controller adding there all text fields and for the...
View ArticleHow to set background color of UIPickerView using UIAppearance?
I am using the following line of code to change the background color of UIPickerView throughout my app as it is for a theme in the app. This changes nothing. [[UIPickerView appearance]...
View ArticleDisable text editing when input view is set for text field
How to disable editing textField manually. I have UIPickerView that I want to use as inputView. But seems I still have ability to copy paste in textfield.I found this question and seems that's what I...
View ArticleHow can I make a smoothed custom Picker on SwiftUI?
I would like to replicate this picker in swiftUI. In particular, I have a button on the bottom left of the screen and when I click it I would like to show different icons (similar to the image below,...
View ArticleWhat is the difference between UIPickerViewDataSource and UIPickerViewModel...
When it comes down to UIPickerView, I've always used a UIPickerViewDataSource to fill my picker view with data. Recently I've found out that there is also an option to use a UIPickerViewModel, but I...
View ArticleSwiftUI picker scroll jumps to next value [closed]
My picker has lot of values which leads to memory issue so I opted UIKit picker in SwiftUI. In SwiftUI If i scroll the picker from top to bottom and vice versa intermittently picker jumps to some other...
View ArticleWhat is the difference between UIPickerViewDataSource and UIPickerViewModel
When it comes down to UIPickerView, I've always used a UIPickerViewDataSource to fill my picker view with data. Recently I've found out that there is also an option to use a UIPickerViewModel, but I...
View ArticleGet the uipickerview value from a .xib file
I am very new to Swift (less than one week) I create a table view where I have more cells , each cell gets create from a .xib file, and the fields get populated because I create an array of objects...
View ArticleHow do I make a UIPickerView rise from the bottom of the app after pressing a...
I'm learning Swift by making an iPhone app. The problem I'm running into involves implementing a UIPickerView. I have a button that should, if pressed, make a UIPickerView ascend from the bottom of the...
View ArticleGet the uipickerview value from a .xib file
I am very new to Swift (less than one week) I create a table view where I have more cells , each cell gets create from a .xib file, and the fields get populated because I create an array of objects...
View ArticleHow to add a line to a UIPickerView?
I've never worked with UIPickerView and now I'm trying to figure it out.Now the standard picker view looks like this:I want to remove the shadow and add lines to it so that it looks like before:My...
View ArticlePicker view inside the text field
I want to use textfield as dropdown with the picker viewannouncementPicker = UIPickerView()announcementPicker.backgroundColor = UIColor(red: 0, green: 0, blue: 0, alpha: 0.5)announcementPicker.delegate...
View ArticleSwift Picker Containing A View Not Showing The Color component
So I want to have a dropdown containing different categories and each category should have a color, the string value of the category should be binded to my viewmodel.category.This is what I...
View ArticleHow can I save several UISwitches and thus display different arrays of a...
I am in the process of programming a small app to calculate exposure times.I have a UiViewController to set the apertures of one Stop, halfStop and thridStop via three UiSwitches.If you set one...
View Articlechange UIPicker height programmatically
I would like to modify the height of UIPicker programmatically, I tried to do this but on the simulator the height remains as it was before, I don't see any changes.@objc open func showPicker(title:...
View Article