Localizing other pages in Settings.bundle - iphone

I have other pages within my app preferences which are stored as separate files within the settings.bundle.
It has come time to localize my app and I can only seem to get the Root values to localize. I was wondering whether there was a trick?
The following image shows that my second screen is stored within a file called "MyPrefs.plist" and I have created a corresponding named file "MyPrefs.strings" in the en.lproj directory. Mirroring the same naming and location as the Root.plist and Root.strings.
The values with the Root.plist are converted as expected but not in the extra screen.
Is there any trick to localizing secondary screens with the settings.bundle?

Have you set the correct value for Strings Filename key in the MyPrefs.plist file ?
It should look like:
+ iPhone Settings Schema
Settings Page Title MyPrefs Title
Strings Filename MyPrefs
+ Preferences Items
....

Related

Localization Strings not shown in SwiftUI

I was making my doc of string for Localization in SwiftUI, but I noticed that some string are nos showing correctly, like if they didn't exists. I thought that it was because I have mi localization file in my main folder, and my ViewFile is in a subfolder, so I created another strings file in my subfolder and localized it but it didn't worked (all is indicated in red).
But a string is showed correctly in my Setting View that it's in another subfolder (indicated in green).

Unable to rename ios application via CFBundleDisplayName

I want to change the application name that shown below is app icon. but i am unable to do this from info.plist file.
I have tried changing following value:
Bundle display name:${PRODUCT_NAME} ==> Bundle display name:${MyApp}.
But it didn't worked.
The app name doesn't need to be surrounded by ${}
My App
instead of
${MyApp}
If you are changing the value in the default view for the plist, it should look like this:
Including the ${} indicates that the plist should get the value with key "MyApp" from the build settings.

Is it possible to show dynamic data in default Settings app from my app

I am using settings bundle to insert some items in iPhone's default settings app.
now when selecting my app name  from iPhone's settings app , can we able to list data from Database of my application.
When checking some URLs, it seems that we cant show dynamic data in the settings app.
What i am trying to do is,
Settings -> MyAppName -> When tapped MyAppName
I want to fetch data from my DB and display it like below in the uitableview.also to add new entry by tapping + ( add button ) from there.
Fruits
Vegtables
Icecream
Chocolates
Mobiles
like that and when tapping on the each entry take it to the next set of list. and also there they can add new entry
Can this all be done?
Please let me know
No, sorry, it can't be done. You'll have to have the settings inside your app and include your own view controller for the same purpose.
No you can not do this, because as a app you can write only to the documents directory of your app. So to have something displayed in the settings you have to create Settings.bundle in your main bundle. You can read from your main bundle the Settings.bundle files but you can not write to it.

How to Show a GPL licence in iphone application bundle

i am making an app for iphone and for that i am using certain free libraries.My problem is that i want to show their complete license of nearly 4-5 pages in my application bundle so that a user can open settings in iphone and see that licensing page at one time but i am unable to do it.I have read these Specifiers for making an application bundle .
PSGroupSpecifier
PSTitleValueSpecifier
PSTextFieldSpecifier
PSSliderSpecifier
PSToggleSwitchSpecifier
PSMultiValueSpecifier
PSChildPaneSpecifier
but i want to show a page full of text like Settings->General->About->Leagl
just like in iphone through PSChildPaneSpecifier .Please help me how to do this>???
Thanks
You can create the same effect as used by Apple's iWorks apps for the license > section of the settings, without using any custom preference controller. Note this works for iOS 5 on the iPad, I have not tried it elsewhere. Use a PSChildPaneSpecifier for the initial control in the root plist. This points to the name of another plist file which will be the displayed child pane. You do not add .plist to the name within the root.plist file, it is implied. This plist file must be within the settings bundle. Next, use PSGroupSpecifiers in the child pane as the controls. For each paragraph use another PSGroupSpecifier - so the thing will scroll. Only use the Title section of the PSGroupSpecifier. The next gotcha that I found, was that by putting the strings in the plist file, the text was clipped in portrait orientation, so a placeholder string needs to go in the plist file and a StringTable used to point to a strings file. Text read from the strings file is properly kerned and displays without clipping.
The iPhone's "Legal" page is a custom preference controller which you can't use (not even with undocumented methods – you need to write a preference bundle in system locations which AppStore apps can't reach at all).
If you'd like to display the license, show it in the app.
I think you are going to need to use something like a UITextView, just make it non-editable. You can make in unobtrusive in your app but I think that is the only way to have 4-5 pages.
I don't think there is a nice way of displaying this in the preferences bundle. Personally I would either provide a series of url links or bring the preferences into the app itself. There is a good framework on github here that you may be able to modify.

Can I change the icon title on the iPhone home screen without changing the application name?

The name of an app we are developing is longer than can fit under the icon on the home screen, but it looks fine everywhere else it appears in the UI (like when a popup appears asking you if you want to delete it, in the settings app, etc.).
Is there any way to specify a different string for these different places?
You can specify two different bundle names in your Info.plist:
CFBundleDisplayName:
CFBundleDisplayName (String) specifies
the display name of the bundle. If you
support localized names for your
bundle, include this key in both your
information property list file and in
the InfoPlist.strings files of your
language subdirectories. If you
localize this key, you should also
include a localized version of the
CFBundleName key.
CFBundleName:
CFBundleName (String) identifies the
short name of the bundle. This name
should be less than 16 characters long
and be suitable for displaying in the
menu bar and the application’s Info
window. You can include this key in
the InfoPlist.strings file of an
appropriate .lproj subdirectory to
provide localized values for it. If
you localize this key, you should also
include the key “CFBundleDisplayName.”
In Xcode these show up as "Bundle display name" and "Bundle name" respectively.
So just change the value of Bundle name to a shortened form and see if the dashboard uses that instead of the longer Bundle display name
Except for localized application names, I'm not aware of any option to specify different application names for different contexts.