Means to use Color Swatch in settings? - ios

I'd hoped to find that someone's worked out a means to provide a choice of colors from the application settings (even with InAppSettings) with some kind of view of the (graphical) color swatch itself. My fallback implementation is a settings child pane of text multi-values of a small set of colors obviously without any swatch (unless there's a way of using icon.pngs therein).
Is someone aware such an implementation?

There is currently no approved way to do what you ask besides RGB values, and even then it's not user friendly. I can recommend two projects if you would like to provide a pallet in-app though:
IL Color Picker is simply excellent. I cannot recommend it highly enough. It's intuitive, and unique, and it looks like photoshop's implementation.
Color Picker a control styled like a nib's default color pallet.

Related

iOS Accessibility – Detect if Colour Filters is on?

In iOS, you can set Colour Filters which is helpful for Colour Blind users. Is it possible or any way we can know if this is turned on / off?
The documentation does not mention such a thing and there is no UIAccessibility boolean that returns whether color filters are enabled (unlike for inverted colors), so it's safe to assume that there isn't a public API to detect this from an app.
However, this isn't necessarily a problem. Use color schemes in your app in a way that won't distract or confuse users with visual disabilities in the first place.

Are there any convenient ways for managing color schemes in an iOS app?

I was wondering if there are any standard or convenient ways for managing color schemes with storyboards in an iOS app, instead of having to manually change the colors of many different UI objects.
Thanks!
There is a tintColor that a few interface elements will pick up by default. You can configure the storyboard (right side menu) on the Global Tint setting.
If you want more costumization, there is a cool recent feature called UIAppearance. It lets you costumize interface elements by code, and that is applied in all such elements across the app.
Here is more info:
http://nshipster.com/uiappearance/
This is a fine question. We once had to do a complete color palette adjustment in a very large (> 100 view controller) app, and it was a suboptimal experience. For colors that are defined in code, the changes were easy enough. For colors specified in xibs or storyboards, though, it sucked. Because IB stores colors as raw double RGB values, there's no easy way to grep through the xib and storyboard xml files to do a simple search and replace. I wound up having to write a Ruby script that would find RGB values in the XML files, convert the doubles to integers in the (0..255) range, and then prompt the user to enter new values. The script cached the user's answers so that the user wasn't prompted multiple times for the same color values.
In hindsight, I still would prefer to specify colors in the storyboards & xibs so that it's as WYSIWYG as possible, and instead insist that the designers can make the changes themselves if they ever decide to modify the palette. :)

Change brightness of application

Is it possible to programmatically change the brightness of a C++ Builder/Delphi styled application, without actually changing the style and loading it back in real time? Could not find anything like a master brightness setting. Note I do not want to change the brightness of the entire screen, just the styled elements in my application (like Adobe does).
Update: referring to VCL, not FMX.
I'm not sure if this would work for you, but could you use a TContrastEffect? It has both a brightness and contrast property that should affect the object it's parented to and it's children when adjusted.

Can the iOS8 InvertColors function be called in an apps code?

iOS now has a setting in General, accessibility, "Invert Colors". It basically provides a negative image of an app's colors.
I have an app that is mostly dark background elements with light icons and buttons. It would be great to have a setting inside my app to call that invert colors function as needed for specific users.
Any ideas if that setting is exposed? Thanks much!
In general you have no access to the user's Settings, and this is no exception. Your app can't alter general settings on the user's device; that would be a terrible security hole!
However, nothing stops you from putting up an alert or other dialog suggesting that the user might like to do this.
Alternatively, though, what I would recommend is themes. Basically give the user a preference within the app, so that the user can choose or alter the colors of things. Then, in response to the user's setting, you use the appearance proxy to change all the colors thematically throughout the app. There was a good WWDC video either in 2013 or 2012, I think, on this very idea.

iOS Interface Builder Custom Styles?

Simple question. Does anyone know why Interface Builder doesn't allow for applying custom styles on UI elements? Why is it only possible to do this programmatically?
I can see how this might be difficult for custom UIView subclasses but the default controls definitely only have a tiny subset of the style options available through IB, such as background color or changing font colors. Why is this the case? Is there any way to approach a concept like application themes through IB?
My personal feeling is that Apple does this right. They provide the elements and styles that fit the HIG. If they start adding other elements/styles then where do the start, and where do they draw the line?
Also, it isn't like Apple actively prevents using custom elements/styles, they just don't include it in the tool set.
The last thing we need is a tool set full of bloat.
You'd really have to ask Apple as to the why. I'd guess that it's some combination of promoting consistent use of standard interface elements and limited development resources.
You can, of course, build interfaces using your own custom subclasses of the standard interface elements in IB. It's a little more work, since you have to change the type of each object you add from UIButton to MyGreenButton or whatever, but it's not difficult.
It's also not hard to imagine coming up with a controller-type class that could connect to all your controls and whatnot to customize their appearance in some consistent, theme-like manner. Add an instance of that to each nib, connect all the controls, and let it do it's thing. You wouldn't see the effect until you actually run the app, of course, but it sounds like you're talking about customizing colors and fonts rather than size.
Unfortunately you are at the mercy of the Almighty Apple Deity..... Bow at their feet and give thanks that you have what they give you..... lol...
Seriously tho. Apple puts in what apple wants and you can request additions, but the IB is fairly minimal in the way of features.
I think this may be by design. Somehow an Elegant Simplicity ?
The ability to customize the controls is given to the programmer however I think they want the controls standardized. I just dont know why they didnt give a little more variety in the controls that are available. Like a few more button styles for the ios devices...
If you find out otherwise I would definitely be all ears.
I think that apple should let you to customize more the controls, for games it takes too much time to make the custom control ( you can make it faster in android as you can configure it in xml)
Btw PaintCode is another option to make your own style for components, it will generate the code but its more like interface builder
http://www.paintcodeapp.com/

Resources