0
Good afternoon. 09/05/2017
I have the following pickerview:
As you can see right away the first item of the two lists does not appear the whole name.
I guess because of the size.
On the left side the full name is: "BEER DA BOA"
On the right side your items are: "BEER DA BOA 01", "BEER DA BOA 02"
I wonder if you have how to change the font size of the pickerview or if you have the full description of the items to be visible.
I tried to use the code below, but despite changing the font COLOR, does not change the font size.
func pickerView(_ pickerView: UIPickerView, attributedTitleForRow row: Int, forComponent component: Int) -> NSAttributedString?
{// MUDA A COR DAS LINHAS
var myTitle = NSAttributedString();
if component == 0
{
let titleData = vLocal[row] as! Bebida_Class;
myTitle = NSAttributedString(string: titleData.bebida_descricao,
attributes: [NSFontAttributeName:UIFont(name: "Georgia", size: 10.0)!,
NSForegroundColorAttributeName:UIColor.blue])
}
if component == 1
{
etc....
}
return myTitle
}
Thank you for your attention..
ps1 : If anyone Edit this post, please do NOT take words, as the same, including thanks, are to form a whole.
Good afternoon Edson <br> As I always say to everyone, you have to ask who KNOWS :) <br> Perfect your answer.. Now I can see all the items on the left and right side... I felt very MALE :)<br> My level in Swift programming is EASE-DRINKING... I still have a lot of time ahead. <br> My thanks so much for your help :) Hugs
– Ricardo M.Souza
Rsrsrsrs, when we are learning it’s like that, no one is born knowing anything, but over time and as you need to use things you will learn.
– Edson Guido