Create New Settings Page - accessibilitysoftwarehub/OpenSourceWindowsGazeControl GitHub Wiki

Add new page to settings

Each page in settings is a panel. To create a new page add a new panel and place all the page's content inside. To make the new page gaze reactive you will want to create a behavior map for it; Using the same behavior map for multiple pages may cause some controls to lose gaze reactive functionality if they overlap in position on the different pages.

Add new behavior maps

To add a new behavior map go to Settings.Designer.cs and add a new BehavMap variable. Then in InitializeComponent() method initialize the new BehavMap.

show settings show settings

Or right click one of the existing behavior maps and copy / paste it.

You do not need to do anything to join the panel and behavior map but you will need to add the name of the panel to the SettingState enum, at the top of Settings.cs.

For binding controls to a behavior map Click Here.

Showing settings panel

To show a settings panel pass the panel to the changePanel() method.

If the panel has a behavior map you will need to pass the SettingState for the page to the UseMap() method.

If using the navigation buttons at the top use ChangeButtonColor(), pass in the selected button and set it to true, true. Pass all other navigation buttons to ChangeButtonColor() and set them to false, true. This will highlight the selected navigation button.

show settings