UI Accessibility Plugin  Version 1.0.0
Make your UI accessible for visually impaired users
Enable NGUI Support

NGUI is one of the most popular UI plugins for Unity. It's being developed by Tasharen Entertainment and can be found in the Unity Asset Store here.
UAP is compatible with UIs created with NGUI, after enabling support in the Settings.

NGUI

This page will explain how to set up UAP to work with NGUI.

Setting up UAP for NGUI

Because NGUI is a separate plugin, support must be explicitly enabled to avoid compile errors.
You can either do this manually, or have the plugin enable support for you.
Make sure you have NGUI added to your project before enabling the plugin support, or the compiler will throw errors, because it cannot find NGUI's classes.

Enabling NGUI Support

If NGUI is already present in the project, you can simply enable NGUI support in the settings in the Accessibility Manager prefab in your scene.
The plugin will then set the scripting defines for you (for Android, iOS and Standalone) automatically.

If you want to do it manually, you need to add the string "ACCESS_NGUI" to your Scripting Define Symbols.

NGUI Demo Scene

The Examples folder contains a navigation demo scene using NGUI.
This scene will only work if you have NGUI installed and setup as described on this page.

Trouble Shooting

NGUI Version

The current version of UAP was tested with NGUI version 3.11.2
Depending on which version of NGUI you are using the interfaces can change and become incompatible with the existing code.
If you are using a different version and encounter compilation errors, please check the support forums for updated code snippets or post with a support request.

Touch Blocker and Focus Frame

When active, the plugin needs to prevent blind users from accidentally pressing buttons on the screen. Read this for more details.
For NGUI the touch blocker panel is created dynamically and added to the UI root in the scene after level load. It's depth is set to 11000. Similarly the item frame is place on a panel with depth 12000.
If you have panels with a higher depth, or need to modify this for any other reason, you can adjust the code in the functions UAP_AccessibilityManager::CreateNGUITouchBlocker() and UAP_AccessibilityManager::CreateNGUIItemFrame() respectively.

Compile Error: The type or namespace name `UIWidget' could not be found

This error only happens if NGUI support is enabled, but NGUI is not present in the project.
Please double check that NGUI is imported.

Traversal Order

Because of the way NGUI anchors UI elements and uses its pixel perfect mode, the position of individual UI elements can shift up or down by one pixel during actual gameplay. This can have the undesired effect that elements that are in a row next to each other are traversed in what appears to be a random order.
There are two possible solutions - you can either specify a manual traversal order, or work with dummy widgets and set up reference Targets.
These options are documented here: Manual Traversal Order and Reference Targets