Enhance AIImages mod with settings support and improved UI for image generation. Update localized strings in English and Russian for better clarity. Refactor code for better organization and maintainability.

This commit is contained in:
Leonid Pershin
2025-10-26 18:09:30 +03:00
parent 990c8695b7
commit 0f60721162
17 changed files with 1907 additions and 335 deletions

View File

@@ -2,19 +2,21 @@
<LanguageData>
<!-- Gizmo (button) -->
<AIImages.Gizmo.Label>AI Image</AIImages.Gizmo.Label>
<AIImages.Gizmo.Description>Open AI Image window</AIImages.Gizmo.Description>
<AIImages.Gizmo.Description>Open AI Image window to generate character portraits</AIImages.Gizmo.Description>
<!-- Window -->
<AIImages.Window.Title>AI Image Window</AIImages.Window.Title>
<AIImages.Window.Title>AI Image Generator</AIImages.Window.Title>
<AIImages.Window.PawnLabel>Character: {0}</AIImages.Window.PawnLabel>
<AIImages.Window.Refresh>Refresh</AIImages.Window.Refresh>
<!-- Appearance -->
<AIImages.Appearance.SectionTitle>Appearance</AIImages.Appearance.SectionTitle>
<AIImages.Appearance.NoInfo>Appearance information unavailable</AIImages.Appearance.NoInfo>
<AIImages.Appearance.Gender>Gender: {0}</AIImages.Appearance.Gender>
<AIImages.Appearance.Age>Age: {0} years</AIImages.Appearance.Age>
<AIImages.Appearance.BodyType>Body type: {0}</AIImages.Appearance.BodyType>
<AIImages.Appearance.SkinColor>Skin color: RGB({0}, {1}, {2})</AIImages.Appearance.SkinColor>
<AIImages.Appearance.SkinTone>Skin tone: {0}</AIImages.Appearance.SkinTone>
<AIImages.Appearance.Hairstyle>Hairstyle: {0}</AIImages.Appearance.Hairstyle>
<AIImages.Appearance.HairColor>Hair color: RGB({0}, {1}, {2})</AIImages.Appearance.HairColor>
<AIImages.Appearance.HairColorDesc>Hair color: {0}</AIImages.Appearance.HairColorDesc>
<AIImages.Appearance.Beard>Beard: {0}</AIImages.Appearance.Beard>
<AIImages.Appearance.Traits>Traits:</AIImages.Appearance.Traits>
<!-- Apparel -->
<AIImages.Apparel.SectionTitle>Apparel</AIImages.Apparel.SectionTitle>
@@ -24,9 +26,45 @@
<AIImages.Apparel.Quality> Quality: {0}</AIImages.Apparel.Quality>
<AIImages.Apparel.Material> Material: {0}</AIImages.Apparel.Material>
<AIImages.Apparel.Durability> Durability: {0}/{1} ({2}%)</AIImages.Apparel.Durability>
<AIImages.Apparel.Color> Color: RGB({0}, {1}, {2})</AIImages.Apparel.Color>
<AIImages.Apparel.ColorDesc> Color: {0}</AIImages.Apparel.ColorDesc>
<!-- Stable Diffusion Prompt -->
<AIImages.Prompt.SectionTitle>Stable Diffusion Prompt</AIImages.Prompt.SectionTitle>
<AIImages.Prompt.CopyButton>Copy Prompt</AIImages.Prompt.CopyButton>
<AIImages.Prompt.Copied>Copied!</AIImages.Prompt.Copied>
<!-- Generation -->
<AIImages.Generation.Generate>Generate Image</AIImages.Generation.Generate>
<AIImages.Generation.Generating>Generating...</AIImages.Generation.Generating>
<AIImages.Generation.InProgress>Generating image, please wait...</AIImages.Generation.InProgress>
<AIImages.Generation.Success>Image generated successfully!</AIImages.Generation.Success>
<AIImages.Generation.Failed>Generation failed</AIImages.Generation.Failed>
<AIImages.Generation.SavedTo>Image saved to: {0}</AIImages.Generation.SavedTo>
<AIImages.Generation.NoImage>No image generated yet.\nClick "Generate Image" to start.</AIImages.Generation.NoImage>
<!-- Settings -->
<AIImages.Settings.ApiSection>API Settings</AIImages.Settings.ApiSection>
<AIImages.Settings.ApiSectionTooltip>Configure connection to Stable Diffusion API</AIImages.Settings.ApiSectionTooltip>
<AIImages.Settings.ApiEndpoint>API Endpoint</AIImages.Settings.ApiEndpoint>
<AIImages.Settings.TestConnection>Test Connection</AIImages.Settings.TestConnection>
<AIImages.Settings.LoadModels>Load Available Models</AIImages.Settings.LoadModels>
<AIImages.Settings.ConnectionSuccess>Successfully connected to API!</AIImages.Settings.ConnectionSuccess>
<AIImages.Settings.ConnectionFailed>Failed to connect to API. Check endpoint and ensure Stable Diffusion WebUI is running.</AIImages.Settings.ConnectionFailed>
<AIImages.Settings.ModelsLoaded>Loaded {0} models from API</AIImages.Settings.ModelsLoaded>
<AIImages.Settings.NoModelsFound>No models found. Check API connection.</AIImages.Settings.NoModelsFound>
<AIImages.Settings.GenerationSection>Generation Settings</AIImages.Settings.GenerationSection>
<AIImages.Settings.GenerationSectionTooltip>Configure image generation parameters</AIImages.Settings.GenerationSectionTooltip>
<AIImages.Settings.ArtStyle>Art Style</AIImages.Settings.ArtStyle>
<AIImages.Settings.ShotType>Shot Type</AIImages.Settings.ShotType>
<AIImages.Settings.Steps>Sampling Steps</AIImages.Settings.Steps>
<AIImages.Settings.CfgScale>CFG Scale</AIImages.Settings.CfgScale>
<AIImages.Settings.Width>Width</AIImages.Settings.Width>
<AIImages.Settings.Height>Height</AIImages.Settings.Height>
<AIImages.Settings.Sampler>Sampler</AIImages.Settings.Sampler>
<AIImages.Settings.PromptsSection>Prompts</AIImages.Settings.PromptsSection>
<AIImages.Settings.PromptsSectionTooltip>Base prompts that will be added to all generations</AIImages.Settings.PromptsSectionTooltip>
<AIImages.Settings.BasePositivePrompt>Base Positive Prompt</AIImages.Settings.BasePositivePrompt>
<AIImages.Settings.BaseNegativePrompt>Base Negative Prompt</AIImages.Settings.BaseNegativePrompt>
<AIImages.Settings.OptionsSection>Options</AIImages.Settings.OptionsSection>
<AIImages.Settings.AutoLoadModels>Auto-load models on startup</AIImages.Settings.AutoLoadModels>
<AIImages.Settings.ShowTechnicalInfo>Show technical information</AIImages.Settings.ShowTechnicalInfo>
<AIImages.Settings.SaveHistory>Save generation history</AIImages.Settings.SaveHistory>
<AIImages.Settings.SavePath>Save Path</AIImages.Settings.SavePath>
</LanguageData>