diff options
author | k-m_schindler <k-m_schindler@b956fd51-792f-4845-bead-9b4dfca2ff2c> | 2009-06-27 20:00:24 +0000 |
---|---|---|
committer | k-m_schindler <k-m_schindler@b956fd51-792f-4845-bead-9b4dfca2ff2c> | 2009-06-27 20:00:24 +0000 |
commit | 3604611392c49da4cb0330fde7ec1c14bda32ce1 (patch) | |
tree | 270e7e7dd2c60908dcca18fae457c3f97b1ba3bf | |
parent | ce7cff50423062cb415ad7f2dcfa83c884b03fb4 (diff) | |
download | usdx-3604611392c49da4cb0330fde7ec1c14bda32ce1.tar.gz usdx-3604611392c49da4cb0330fde7ec1c14bda32ce1.tar.xz usdx-3604611392c49da4cb0330fde7ec1c14bda32ce1.zip |
Translation of option values. part 1
git-svn-id: svn://svn.code.sf.net/p/ultrastardx/svn/trunk@1828 b956fd51-792f-4845-bead-9b4dfca2ff2c
-rw-r--r-- | game/languages/English.ini | 60 | ||||
-rw-r--r-- | game/languages/German.ini | 60 | ||||
-rw-r--r-- | src/base/UIni.pas | 245 |
3 files changed, 365 insertions, 0 deletions
diff --git a/game/languages/English.ini b/game/languages/English.ini index a65fa20e..a58d61a8 100644 --- a/game/languages/English.ini +++ b/game/languages/English.ini @@ -1,4 +1,64 @@ [Text] +OPTION_VALUE_EASY=Easy +OPTION_VALUE_MEDIUM=Medium +OPTION_VALUE_HARD=Hard + +OPTION_VALUE_ON=On +OPTION_VALUE_OFF=Off + +OPTION_VALUE_EDITION=Edition +OPTION_VALUE_GENRE=Genre +OPTION_VALUE_LANGUAGE=Language +OPTION_VALUE_FOLDER=Folder +OPTION_VALUE_TITLE=Title +OPTION_VALUE_ARTIST=Artist +OPTION_VALUE_TITLE2=Title2 +OPTION_VALUE_ARTIST2=Artist2 + +OPTION_VALUE_WHENNOVIDEO=WhenNoVideo + +OPTION_VALUE_SMALL=Small +OPTION_VALUE_BIG=Big + +OPTION_VALUE_HALF=Half +OPTION_VALUE_FULL_VID=Full (Video) +OPTION_VALUE_FULL_VID_BG=Full (BG & Video) + +OPTION_VALUE_AUTO=Auto +OPTION_VALUE_SEC=Sec +OPTION_VALUE_SECS=Secs + +OPTION_VALUE_PLAIN=Plain +OPTION_VALUE_OLINE1=OLine1 +OPTION_VALUE_OLINE2=OLine2 + +OPTION_VALUE_SIMPLE=Simple +OPTION_VALUE_ZOOM=Zoom +OPTION_VALUE_SLIDE=Slide +OPTION_VALUE_BALL=Ball +OPTION_VALUE_SHIFT=Shift + +OPTION_VALUE_EURO=Euro +OPTION_VALUE_JAPAN=Japan +OPTION_VALUE_AMERICAN=American + +OPTION_VALUE_BLUE=Blue +OPTION_VALUE_GREEN=Green +OPTION_VALUE_PINK=Pink +OPTION_VALUE_RED=Red +OPTION_VALUE_VIOLET=Violet +OPTION_VALUE_ORANGE=Orange +OPTION_VALUE_YELLOW=Yellow +OPTION_VALUE_BROWN=Brown +OPTION_VALUE_BALCK=Black + +OPTION_VALUE_SING=Sing +OPTION_VALUE_SELECT_PLAYERS=Select Players +OPTION_VALUE_OPEN_MENU=Open Menu + +OPTION_VALUE_HARDWARE_CURSOR=Hardware Cursor +OPTION_VALUE_SOFTWARE_CURSOR=Software Cursor + SING_LOADING=Loading... SING_CHOOSE_MODE=choose mode diff --git a/game/languages/German.ini b/game/languages/German.ini index 4ea0bf89..c3df6041 100644 --- a/game/languages/German.ini +++ b/game/languages/German.ini @@ -1,4 +1,64 @@ [Text] +OPTION_VALUE_EASY=Einfach +OPTION_VALUE_MEDIUM=Mittel +OPTION_VALUE_HARD=Schwierig + +OPTION_VALUE_ON=An +OPTION_VALUE_OFF=Aus + +OPTION_VALUE_EDITION=Edition +OPTION_VALUE_GENRE=Genre +OPTION_VALUE_LANGUAGE=Sprache +OPTION_VALUE_FOLDER=Ordner +OPTION_VALUE_TITLE=Titel +OPTION_VALUE_ARTIST=Künstler +OPTION_VALUE_TITLE2=Titel2 +OPTION_VALUE_ARTIST2=Künstler2 + +OPTION_VALUE_WHENNOVIDEO=Wenn kein Video + +OPTION_VALUE_SMALL=Klein +OPTION_VALUE_BIG=Gross + +OPTION_VALUE_HALF=Halb +OPTION_VALUE_FULL_VID=Voll (Video) +OPTION_VALUE_FULL_VID_BG=Voll (HG & Video) + +OPTION_VALUE_AUTO=Automatisch +OPTION_VALUE_SEC=Sek +OPTION_VALUE_SECS=Sekn + +OPTION_VALUE_PLAIN=Einfach +OPTION_VALUE_OLINE1=OLine1 +OPTION_VALUE_OLINE2=OLine2 + +OPTION_VALUE_SIMPLE=Einfach +OPTION_VALUE_ZOOM=Vergrössern +OPTION_VALUE_SLIDE=Rutschen +OPTION_VALUE_BALL=Ball +OPTION_VALUE_SHIFT=Schieben + +OPTION_VALUE_EURO=Europäisch +OPTION_VALUE_JAPAN=Japanisch +OPTION_VALUE_AMERICAN=Amerikanisch + +OPTION_VALUE_BLUE=Blau +OPTION_VALUE_GREEN=Grün +OPTION_VALUE_PINK=Lila +OPTION_VALUE_RED=Rot +OPTION_VALUE_VIOLET=Violett +OPTION_VALUE_ORANGE=Orange +OPTION_VALUE_YELLOW=Gelb +OPTION_VALUE_BROWN=Braun +OPTION_VALUE_BALCK=Schwarz + +OPTION_VALUE_SING=Singen +OPTION_VALUE_SELECT_PLAYERS=Spieler auswählen +OPTION_VALUE_OPEN_MENU=Menu öffnen + +OPTION_VALUE_HARDWARE_CURSOR=Hardware Zeiger +OPTION_VALUE_SOFTWARE_CURSOR=Software Zeiger + SING_LOADING=Lädt... SING_CHOOSE_MODE=Modus wählen diff --git a/src/base/UIni.pas b/src/base/UIni.pas index 0654f516..2bcc7305 100644 --- a/src/base/UIni.pas +++ b/src/base/UIni.pas @@ -77,6 +77,7 @@ type function ReadArrayIndex(const SearchArray: array of string; IniFile: TCustomIniFile; IniSection: string; IniProperty: string; Default: integer): integer; + procedure TranslateOptionValues; procedure LoadInputDeviceCfg(IniFile: TMemIniFile); procedure SaveInputDeviceCfg(IniFile: TIniFile); procedure LoadThemes(IniFile: TCustomIniFile); @@ -252,6 +253,65 @@ const IChannelPlayer: array[0..6] of string = ('Off', '1', '2', '3', '4', '5', '6'); IMicBoost: array[0..3] of string = ('Off', '+6dB', '+12dB', '+18dB'); +var + IDifficultyTranslated: array[0..2] of string = ('Easy', 'Medium', 'Hard'); + ITabsTranslated: array[0..1] of string = ('Off', 'On'); + + ISortingTranslated: array[0..7] of string = ('Edition', 'Genre', 'Language', 'Folder', 'Title', 'Artist', 'Title2', 'Artist2'); + + IDebugTranslated: array[0..1] of string = ('Off', 'On'); + + IFullScreenTranslated: array[0..1] of string = ('Off', 'On'); + IVisualizerTranslated: array[0..2] of string = ('Off', 'WhenNoVideo','On'); + + IBackgroundMusicTranslated: array[0..1] of string = ('Off', 'On'); + ISingWindowTranslated: array[0..1] of string = ('Small', 'Big'); + + //SingBar Mod + IOscilloscopeTranslated: array[0..1] of string = ('Off', 'On'); + + ISpectrumTranslated: array[0..1] of string = ('Off', 'On'); + ISpectrographTranslated: array[0..1] of string = ('Off', 'On'); + IMovieSizeTranslated: array[0..2] of string = ('Half', 'Full [Vid]', 'Full [BG+Vid]'); + + IClickAssistTranslated: array[0..1] of string = ('Off', 'On'); + IBeatClickTranslated: array[0..1] of string = ('Off', 'On'); + ISavePlaybackTranslated: array[0..1] of string = ('Off', 'On'); + + IVoicePassthroughTranslated: array[0..1] of string = ('Off', 'On'); + + //Song Preview + IPreviewVolumeTranslated: array[0..10] of string = ('Off', '10%', '20%', '30%', '40%', '50%', '60%', '70%', '80%', '90%', '100%'); + + IAudioOutputBufferSizeTranslated: array[0..9] of string = ('Auto', '256', '512', '1024', '2048', '4096', '8192', '16384', '32768', '65536'); + + IAudioInputBufferSizeTranslated: array[0..9] of string = ('Auto', '256', '512', '1024', '2048', '4096', '8192', '16384', '32768', '65536'); + + IPreviewFadingTranslated: array[0..5] of string = ('Off', '1 Sec', '2 Secs', '3 Secs', '4 Secs', '5 Secs'); + + ILyricsFontTranslated: array[0..2] of string = ('Plain', 'OLine1', 'OLine2'); + ILyricsEffectTranslated: array[0..4] of string = ('Simple', 'Zoom', 'Slide', 'Ball', 'Shift'); + ISolmizationTranslated: array[0..3] of string = ('Off', 'Euro', 'Jap', 'American'); + INoteLinesTranslated: array[0..1] of string = ('Off', 'On'); + + IColorTranslated: array[0..8] of string = ('Blue', 'Green', 'Pink', 'Red', 'Violet', 'Orange', 'Yellow', 'Brown', 'Black'); + + // Advanced + ILoadAnimationTranslated: array[0..1] of string = ('Off', 'On'); + IEffectSingTranslated: array[0..1] of string = ('Off', 'On'); + IScreenFadeTranslated: array[0..1] of string = ('Off', 'On'); + IAskbeforeDelTranslated: array[0..1] of string = ('Off', 'On'); + IOnSongClickTranslated: array[0..2] of string = ('Sing', 'Select Players', 'Open Menu'); + ILineBonusTranslated: array[0..1] of string = ('Off', 'On'); + IPartyPopupTranslated: array[0..1] of string = ('Off', 'On'); + + IJoypadTranslated: array[0..1] of string = ('Off', 'On'); + IMouseTranslated: array[0..2] of string = ('Off', 'Hardware Cursor', 'Software Cursor'); + + // Recording options + IChannelPlayerTranslated: array[0..6] of string = ('Off', '1', '2', '3', '4', '5', '6'); + IMicBoostTranslated: array[0..3] of string = ('Off', '+6dB', '+12dB', '+18dB'); + implementation uses @@ -266,6 +326,188 @@ uses UPath; (** + * Translate and set the values of options, which need translation. + *) +procedure TIni.TranslateOptionValues; +begin + ULanguage.Language.ChangeLanguage(ILanguage[Language]); + + IDifficultyTranslated[0] := ULanguage.Language.Translate('OPTION_VALUE_EASY'); + IDifficultyTranslated[1] := ULanguage.Language.Translate('OPTION_VALUE_MEDIUM'); + IDifficultyTranslated[2] := ULanguage.Language.Translate('OPTION_VALUE_HARD'); + + ITabsTranslated[0] := ULanguage.Language.Translate('OPTION_VALUE_OFF'); + ITabsTranslated[1] := ULanguage.Language.Translate('OPTION_VALUE_ON'); + + ISortingTranslated[0] := ULanguage.Language.Translate('OPTION_VALUE_EDITION'); + ISortingTranslated[1] := ULanguage.Language.Translate('OPTION_VALUE_GENRE'); + ISortingTranslated[2] := ULanguage.Language.Translate('OPTION_VALUE_LANGUAGE'); + ISortingTranslated[3] := ULanguage.Language.Translate('OPTION_VALUE_FOLDER'); + ISortingTranslated[4] := ULanguage.Language.Translate('OPTION_VALUE_TITLE'); + ISortingTranslated[5] := ULanguage.Language.Translate('OPTION_VALUE_ARTIST'); + ISortingTranslated[6] := ULanguage.Language.Translate('OPTION_VALUE_TITLE2'); + ISortingTranslated[7] := ULanguage.Language.Translate('OPTION_VALUE_ARTIST2'); + + IDebugTranslated[0] := ULanguage.Language.Translate('OPTION_VALUE_OFF'); + IDebugTranslated[1] := ULanguage.Language.Translate('OPTION_VALUE_ON'); + + IFullScreenTranslated[0] := ULanguage.Language.Translate('OPTION_VALUE_OFF'); + IFullScreenTranslated[1] := ULanguage.Language.Translate('OPTION_VALUE_ON'); + + IVisualizerTranslated[0] := ULanguage.Language.Translate('OPTION_VALUE_OFF'); + IVisualizerTranslated[1] := ULanguage.Language.Translate('OPTION_VALUE_WHENNOVIDEO'); + IVisualizerTranslated[2] := ULanguage.Language.Translate('OPTION_VALUE_ON'); + + IBackgroundMusicTranslated[0] := ULanguage.Language.Translate('OPTION_VALUE_OFF'); + IBackgroundMusicTranslated[1] := ULanguage.Language.Translate('OPTION_VALUE_ON'); + + ISingWindowTranslated[0] := ULanguage.Language.Translate('OPTION_VALUE_SMALL'); + ISingWindowTranslated[1] := ULanguage.Language.Translate('OPTION_VALUE_BIG'); + + IOscilloscopeTranslated[0] := ULanguage.Language.Translate('OPTION_VALUE_OFF'); + IOscilloscopeTranslated[1] := ULanguage.Language.Translate('OPTION_VALUE_ON'); + + ISpectrumTranslated[0] := ULanguage.Language.Translate('OPTION_VALUE_OFF'); + ISpectrumTranslated[1] := ULanguage.Language.Translate('OPTION_VALUE_ON'); + + ISpectrographTranslated[0] := ULanguage.Language.Translate('OPTION_VALUE_OFF'); + ISpectrographTranslated[1] := ULanguage.Language.Translate('OPTION_VALUE_ON'); + + IMovieSizeTranslated[0] := ULanguage.Language.Translate('OPTION_VALUE_HALF'); + IMovieSizeTranslated[1] := ULanguage.Language.Translate('OPTION_VALUE_FULL_VID'); + IMovieSizeTranslated[2] := ULanguage.Language.Translate('OPTION_VALUE_FULL_VID_BG'); + + IClickAssistTranslated[0] := ULanguage.Language.Translate('OPTION_VALUE_OFF'); + IClickAssistTranslated[1] := ULanguage.Language.Translate('OPTION_VALUE_ON'); + + IBeatClickTranslated[0] := ULanguage.Language.Translate('OPTION_VALUE_OFF'); + IBeatClickTranslated[1] := ULanguage.Language.Translate('OPTION_VALUE_ON'); + + ISavePlaybackTranslated[0] := ULanguage.Language.Translate('OPTION_VALUE_OFF'); + ISavePlaybackTranslated[1] := ULanguage.Language.Translate('OPTION_VALUE_ON'); + + IVoicePassthroughTranslated[0] := ULanguage.Language.Translate('OPTION_VALUE_OFF'); + IVoicePassthroughTranslated[1] := ULanguage.Language.Translate('OPTION_VALUE_ON'); + + ILyricsFontTranslated[0] := ULanguage.Language.Translate('OPTION_VALUE_PLAIN'); + ILyricsFontTranslated[1] := ULanguage.Language.Translate('OPTION_VALUE_OLINE1'); + ILyricsFontTranslated[2] := ULanguage.Language.Translate('OPTION_VALUE_OLINE2'); + + ILyricsEffectTranslated[0] := ULanguage.Language.Translate('OPTION_VALUE_SIMPLE'); + ILyricsEffectTranslated[1] := ULanguage.Language.Translate('OPTION_VALUE_ZOOM'); + ILyricsEffectTranslated[2] := ULanguage.Language.Translate('OPTION_VALUE_SLIDE'); + ILyricsEffectTranslated[3] := ULanguage.Language.Translate('OPTION_VALUE_BALL'); + ILyricsEffectTranslated[4] := ULanguage.Language.Translate('OPTION_VALUE_SHIFT'); + + ISolmizationTranslated[0] := ULanguage.Language.Translate('OPTION_VALUE_OFF'); + ISolmizationTranslated[1] := ULanguage.Language.Translate('OPTION_VALUE_EURO'); + ISolmizationTranslated[2] := ULanguage.Language.Translate('OPTION_VALUE_JAPAN'); + ISolmizationTranslated[3] := ULanguage.Language.Translate('OPTION_VALUE_AMERICAN'); + + INoteLinesTranslated[0] := ULanguage.Language.Translate('OPTION_VALUE_OFF'); + INoteLinesTranslated[1] := ULanguage.Language.Translate('OPTION_VALUE_ON'); + + IColorTranslated[0] := ULanguage.Language.Translate('OPTION_VALUE_BLUE'); + IColorTranslated[1] := ULanguage.Language.Translate('OPTION_VALUE_GREEN'); + IColorTranslated[2] := ULanguage.Language.Translate('OPTION_VALUE_PINK'); + IColorTranslated[3] := ULanguage.Language.Translate('OPTION_VALUE_RED'); + IColorTranslated[4] := ULanguage.Language.Translate('OPTION_VALUE_VIOLET'); + IColorTranslated[5] := ULanguage.Language.Translate('OPTION_VALUE_ORANGE'); + IColorTranslated[6] := ULanguage.Language.Translate('OPTION_VALUE_YELLOW'); + IColorTranslated[7] := ULanguage.Language.Translate('OPTION_VALUE_BROWN'); + IColorTranslated[8] := ULanguage.Language.Translate('OPTION_VALUE_BALCK'); + + // Advanced + ILoadAnimationTranslated[0] := ULanguage.Language.Translate('OPTION_VALUE_OFF'); + ILoadAnimationTranslated[1] := ULanguage.Language.Translate('OPTION_VALUE_ON'); + + IEffectSingTranslated[0] := ULanguage.Language.Translate('OPTION_VALUE_OFF'); + IEffectSingTranslated[1] := ULanguage.Language.Translate('OPTION_VALUE_ON'); + + IScreenFadeTranslated[0] := ULanguage.Language.Translate('OPTION_VALUE_OFF'); + IScreenFadeTranslated[1] := ULanguage.Language.Translate('OPTION_VALUE_ON'); + + IAskbeforeDelTranslated[0] := ULanguage.Language.Translate('OPTION_VALUE_OFF'); + IAskbeforeDelTranslated[1] := ULanguage.Language.Translate('OPTION_VALUE_ON'); + + IOnSongClickTranslated[0] := ULanguage.Language.Translate('OPTION_VALUE_SING'); + IOnSongClickTranslated[1] := ULanguage.Language.Translate('OPTION_VALUE_SELECT_PLAYERS'); + IOnSongClickTranslated[2] := ULanguage.Language.Translate('OPTION_VALUE_OPEN_MENU'); + + ILineBonusTranslated[0] := ULanguage.Language.Translate('OPTION_VALUE_OFF'); + ILineBonusTranslated[1] := ULanguage.Language.Translate('OPTION_VALUE_ON'); + + IPartyPopupTranslated[0] := ULanguage.Language.Translate('OPTION_VALUE_OFF'); + IPartyPopupTranslated[1] := ULanguage.Language.Translate('OPTION_VALUE_ON'); + + IJoypadTranslated[0] := ULanguage.Language.Translate('OPTION_VALUE_OFF'); + IJoypadTranslated[1] := ULanguage.Language.Translate('OPTION_VALUE_ON'); + + IMouseTranslated[0] := ULanguage.Language.Translate('OPTION_VALUE_OFF'); + IMouseTranslated[1] := ULanguage.Language.Translate('OPTION_VALUE_HARDWARE_CURSOR'); + IMouseTranslated[2] := ULanguage.Language.Translate('OPTION_VALUE_SOFTWARE_CURSOR'); + + IAudioOutputBufferSizeTranslated[0] := ULanguage.Language.Translate('OPTION_VALUE_AUTO'); + IAudioOutputBufferSizeTranslated[1] := '256'; + IAudioOutputBufferSizeTranslated[2] := '512'; + IAudioOutputBufferSizeTranslated[3] := '1024'; + IAudioOutputBufferSizeTranslated[4] := '2048'; + IAudioOutputBufferSizeTranslated[5] := '4096'; + IAudioOutputBufferSizeTranslated[6] := '8192'; + IAudioOutputBufferSizeTranslated[7] := '16384'; + IAudioOutputBufferSizeTranslated[8] := '32768'; + IAudioOutputBufferSizeTranslated[9] := '65536'; + + + IAudioInputBufferSizeTranslated[0] := ULanguage.Language.Translate('OPTION_VALUE_AUTO'); + IAudioInputBufferSizeTranslated[1] := '256'; + IAudioInputBufferSizeTranslated[2] := '512'; + IAudioInputBufferSizeTranslated[3] := '1024'; + IAudioInputBufferSizeTranslated[4] := '2048'; + IAudioInputBufferSizeTranslated[5] := '4096'; + IAudioInputBufferSizeTranslated[6] := '8192'; + IAudioInputBufferSizeTranslated[7] := '16384'; + IAudioInputBufferSizeTranslated[8] := '32768'; + IAudioInputBufferSizeTranslated[9] := '65536'; + + //Song Preview + IPreviewVolumeTranslated[0] := ULanguage.Language.Translate('OPTION_VALUE_OFF'); + IPreviewVolumeTranslated[1] := '10%'; + IPreviewVolumeTranslated[2] := '20%'; + IPreviewVolumeTranslated[3] := '30%'; + IPreviewVolumeTranslated[4] := '40%'; + IPreviewVolumeTranslated[5] := '50%'; + IPreviewVolumeTranslated[6] := '60%'; + IPreviewVolumeTranslated[7] := '70%'; + IPreviewVolumeTranslated[8] := '80%'; + IPreviewVolumeTranslated[9] := '90%'; + IPreviewVolumeTranslated[10] := '100%'; + + + IPreviewFadingTranslated[0] := ULanguage.Language.Translate('OPTION_VALUE_OFF'); + IPreviewFadingTranslated[1] := '1 ' + ULanguage.Language.Translate('OPTION_VALUE_SEC'); + IPreviewFadingTranslated[2] := '2 ' + ULanguage.Language.Translate('OPTION_VALUE_SECS'); + IPreviewFadingTranslated[3] := '3 ' + ULanguage.Language.Translate('OPTION_VALUE_SECS'); + IPreviewFadingTranslated[4] := '4 ' + ULanguage.Language.Translate('OPTION_VALUE_SECS'); + IPreviewFadingTranslated[5] := '5 ' + ULanguage.Language.Translate('OPTION_VALUE_SECS'); + + // Recording options + IChannelPlayerTranslated[0] := ULanguage.Language.Translate('OPTION_VALUE_OFF'); + IChannelPlayerTranslated[1] := '1'; + IChannelPlayerTranslated[2] := '2'; + IChannelPlayerTranslated[3] := '3'; + IChannelPlayerTranslated[4] := '4'; + IChannelPlayerTranslated[5] := '5'; + IChannelPlayerTranslated[6] := '6'; + + IMicBoostTranslated[0] := ULanguage.Language.Translate('OPTION_VALUE_OFF'); + IMicBoostTranslated[1] := '+6dB'; + IMicBoostTranslated[2] := '+12dB'; + IMicBoostTranslated[3] := '+18dB'; + +end; + +(** * Returns the filename without its fileextension *) function TIni.RemoveFileExt(FullName: string): string; @@ -589,6 +831,7 @@ begin end; // reverse order + Log.LogStatus( 'Log size of resolution: ' + IntToStr(Length(IResolution)), 'Video'); for I := 0 to (Length(IResolution) div 2) - 1 do begin swap(IResolution[I], IResolution[High(IResolution)-I]); @@ -775,6 +1018,8 @@ begin LoadPaths(IniFile); + TranslateOptionValues; + IniFile.Free; end; |