<?xml version="1.0"?>

<!-- Copyright (c) 2026 Josh Davidson (Octal450) -->

<PropertyList>

	<name>acconfig-rendering</name>
	<layout>vbox</layout>
	
	<group>
		<layout>hbox</layout>
		
		<text>
			<halign>left</halign>
			<label>Rendering Settings</label>
		</text>
		
		<button>
			<halign>right</halign>
			<pref-width>20</pref-width>
			<pref-height>20</pref-height>
			<legend>X</legend>
			<key>Esc</key>
			<binding>
				<command>dialog-close</command>
			</binding>
		</button>
	</group>
	
	<hrule/>
	
	<group>
		<layout>vbox</layout>
		
		<text>
			<halign>left</halign>
			<label>Aircraft Config has detected that rendering settings are not set properly!</label>
		</text>
		
		<text>
			<halign>left</halign>
			<label>This means lighting effects on the exterior and in the virtual cockpit will not be visible.</label>
		</text>
		
		<text>
			<halign>left</halign>
			<label>Atmospheric Light Scattering (ALS) must be on, and some shader settings turned up.</label>
		</text>
		
		<hrule/>
		
		<text>
			<halign>left</halign>
			<label>Would you like Aircraft Config to automatically turn on ALS and fix shader settings?</label>
		</text>
		
		<text>
			<halign>left</halign>
			<label>If the settings do not save after fixing, try quitting FlightGear through File -&gt; Exit after fixing.</label>
		</text>
	
	</group>
	
	<hrule/>
	
	<group>
		<layout>hbox</layout>
	
		<checkbox>
			<label>Do not warn me about rendering settings again</label>
			<halign>center</halign>
			<property>/systems/acconfig/options/no-rendering-warn</property>
			<binding>
				<command>property-toggle</command>
				<property>/systems/acconfig/options/no-rendering-warn</property>
			</binding>
			<binding>
				<command>dialog-apply</command>
			</binding>
			<binding>
				<command>nasal</command>
				<script>acconfig.OPTIONS.write();</script>
			</binding>
			<live>true</live>
		</checkbox>
		
	</group>
	
	<hrule/>
	
	<group>
		<layout>hbox</layout>
		
		<button>
			<halign>center</halign>
			<legend>Yes, fix all settings</legend>
			<pref-width>180</pref-width>
			<binding>
				<command>nasal</command>
				<script>acconfig.RENDERING.fixAll();</script>
			</binding>
			<binding>
				<command>dialog-close</command>
			</binding>
		</button>
		
		<button>
			<halign>center</halign>
			<legend>Yes, but I'll fix shaders myself</legend>
			<pref-width>180</pref-width>
			<binding>
				<command>nasal</command>
				<script>acconfig.RENDERING.fixCore();</script>
			</binding>
			<binding>
				<command>dialog-close</command>
			</binding>
		</button>
		
		<button>
			<halign>center</halign>
			<legend>I don't care</legend>
			<pref-width>180</pref-width>
			<binding>
				<command>dialog-close</command>
			</binding>
		</button>
	
	</group>
	
</PropertyList>
