Find Jobs
Hire Freelancers

iPhone Color Picker View

$20-25 USD

En cours
Publié il y a environ 15 ans

$20-25 USD

Payé lors de la livraison
This project is a color picker view for a larger iPhone application. The color picker will include two subviews: a preset colors view and a custom color view allowing the user to select an RGB color. The view controller will be a subclass of UINavigationController and will include getter and setter properties for controlling the selection in both subviews. The final result should be packaged as an Xcode project for an iPhone application named "Color Picker". ## Deliverables The main view for the application will be implemented as a UINavigationController which will contain a UITabBarController, which will contain two UITableView subviews. The first subview will be a grouped UITableView with one section containing one cell for each preset color. Each cell will display the name of the color, and will have an accessory view of size 40 pixels width and 28 pixels height of that color, surrounded by a 1-pixel black border. The preset colors will have these names and values, in this order: * Black: R 0, G 0, B 0 * White: R 255, G 255, B 255 * Gray: R 127, G 127, B 127 * Red: R 180, G 27, B 27 * Blue: R 21, G 96, B 189 * Green: R 46, G 139, B 87 * Yellow: R 253, G 233, B 16 * Orange: R 255, G 127, B 0 The preset values must be stored as static NSArrays which are initialized by +[ColorPickerRGBController initialize]. The arrays will be presetNames, which stores the name of each preset color as an NSString, and presetColors, which stores the UIColor value of each preset color. The arrays will be accessed by the methods +[ColorPickerRGBController presetNames] and +[ColorPickerRGBController presetColors], resepectively. The selected cell from this section will represent the selected preset color. If the user modifies the RGB color, the currently selected cell in the Preset table will be deselected. The second subview will be a grouped UITableView implemented with four sections, each with one cell. The sections will have headers in this order: Red, Green, Blue, Preview. The cells of the first three sections will consist of a UISlider representing the value of the color (Red, Green, or Blue) in RGB representation, and a UILabel accessory view with text equal to the decimal value of the color, from 0 to 255. The font of the accessory view will be set to [UIFont boldSystemFontOfSize: [UIFont systemFontSize]]. The cell of the fourth section will have a height of 90 pixels and will have a background color of the selected color. It will be updated dynamically when any slider of the first three sections is moved, to reflect the new color. The main controller will be a subclass of UINavigationController named ColorPickerController. Its top navigation item will have a title of "Color Picker". It will be created in Interface Builder as the File's Owner in the file [login to view URL], and will load the tab bar controller from ColorPickerTabBar.xib. The tab bar controller will contain two tabs, "Preset" and "RGB", which will each have a view loaded from [login to view URL] and [login to view URL], with a File's Owner of class ColorPickerPresetController and ColorPickerRGBController, respectively. Each of these will have a view of type UITableView and will populate the table view as described above for the first and second subviews, respectively. The class ColorPickerController will implement the properties "presetColorIndex" and "rgbColor". presetColorIndex will be an NSInteger containing the index of the selected preset color, or -1 if no preset color is selected. Its setter method will select the cell with the index of the preset table view given, or deselect the currently selected cell if -1 is given. rgbColor will equal a UIColor with the red, green and blue values selected and an alpha value of 1.0. Its setter method will set each cell in the RGB table to the value of the red, green or blue component. For reference, the suggested interface of ColorPickerController is shown below. @interface ColorPickerController : UINavigationController { UITableView *presetView, *rgbView; } @property (retain) IBOutlet UITableView *presetView; @property (retain) IBOutlet UITableView *rgbView; @property (assign) NSInteger presetColorIndex; @property (retain) UIColor *rgbColor; @end The suggested implementation of -[ColorPickerController viewDidLoad] is shown below. - (void)viewDidLoad { UITabBarController *tab = (id)[self topViewController]; NSArray *tabs = [login to view URL]; [login to view URL] = [tabs objectAtIndex: 0]; [login to view URL] = [tabs objectAtIndex: 1]; } Note that there is no instance variable for presetColorIndex or rgbColor; their value should be recalculated each time their getter method is called. Their setter method should affect the selection and slider values of the Preset and RGB tables, respectively. You are recommended to add additional rValue, gValue, and bValue properties to the ColorPickerRGBController class which modify the sliders' values automatically.
N° de projet : 3752444

Concernant le projet

1 proposition
Projet à distance
Actif à il y a 15 ans

Cherchez-vous à gagner de l'argent ?

Avantages de faire une offre sur Freelancer

Fixez votre budget et vos délais
Soyez payé pour votre travail
Surlignez votre proposition
Il est gratuit de s'inscrire et de faire des offres sur des travaux
Décerné à :
Avatar de l'utilisateur
See private message.
$21,25 USD en 14 jours
4,8 (37 commentaires)
5,4
5,4

À propos du client

Drapeau de UNITED STATES
United States
5,0
1
Membre depuis mars 23, 2009

Vérification du client

Merci ! Nous vous avons envoyé un lien par e-mail afin de réclamer votre crédit gratuit.
Une erreur a eu lieu lors de l'envoi de votre e-mail. Veuillez réessayer.
Utilisateurs enregistrés Total des travaux publiés
Freelancer ® is a registered Trademark of Freelancer Technology Pty Limited (ACN 142 189 759)
Copyright © 2024 Freelancer Technology Pty Limited (ACN 142 189 759)
Chargement de l'aperçu
Permission donnée pour la géolocalisation.
Votre session de connexion a expiré et vous avez été déconnecté. Veuillez vous connecter à nouveau.