diff --git a/PrimaryFormParts/PrimaryForm.cs b/PrimaryFormParts/PrimaryForm.cs index 8e3c01f..43b7edd 100644 --- a/PrimaryFormParts/PrimaryForm.cs +++ b/PrimaryFormParts/PrimaryForm.cs @@ -61,11 +61,11 @@ namespace DualScreenDemo private const int offsetXWordCount = 100; private const int offsetYWordCount = 100; - private PictureBox pictureBoxSongIDSearch; + //private PictureBox pictureBoxSongIDSearch; private Button[] numberButtonsSongIDSearch; - private Button modifyButtonSongIDSearch, closeButtonSongIDSearch; - private RichTextBox inputBoxSongIDSearch; + //private Button modifyButtonSongIDSearch, closeButtonSongIDSearch; + //private RichTextBox inputBoxSongIDSearch; private const int offsetXSongID = 100; private const int offsetYSongID = 100; private const int offsetXPinYin = 100; @@ -585,10 +585,10 @@ namespace DualScreenDemo InitializeButtonsForEnglishSingers(); InitializeButtonsForEnglishSongs(); InitializeButtonsForPictureBoxArtistSearch(); - InitializeButtonsForPictureBoxWordCount(); + InitializeButtonsForWordCountSongs(); InitializeButtonsForPinYinSingers(); InitializeButtonsForPinYinSongs(); - InitializeButtonsForPictureBoxSongIDSearch(); + InitializeButtonsForSongIDSearch(); InitializeButtonsForFavoritePictureBox(); InitializePromotionsButton(); InitializeButtonsForPictureBoxToggleLight(); @@ -596,7 +596,7 @@ namespace DualScreenDemo InitializeSoundEffectButtons(); InitializeSyncScreen(); - + InitializeButtonsForSongIDSearch(); InitializeOtherControls(); @@ -609,7 +609,7 @@ namespace DualScreenDemo pictureBoxZhuYinSongs.BringToFront(); pictureBoxEnglishSingers.BringToFront(); pictureBoxEnglishSongs.BringToFront(); - pictureBoxWordCount.BringToFront(); + pictureBoxWordCountSongs.BringToFront(); FavoritePictureBox.BringToFront(); promotionsPictureBox.BringToFront(); pictureBoxToggleLight.BringToFront(); @@ -781,9 +781,9 @@ namespace DualScreenDemo Visible = false }; - pictureBoxWordCount = new PictureBox + pictureBoxWordCountSongs = new PictureBox { - Name = "pictureBoxWordCount", + Name = "pictureBoxWordCountSongs", BackColor = Color.Transparent, SizeMode = PictureBoxSizeMode.StretchImage, Visible = false @@ -897,6 +897,7 @@ namespace DualScreenDemo this.Controls.Add(pictureBox6); this.Controls.Add(pictureBoxQRCode); this.Controls.Add(pictureBoxZhuYinSingers); + this.Controls.Add(pictureBoxWordCountSongs); this.Controls.Add(pictureBoxZhuYinSongs); this.Controls.Add(pictureBoxEnglishSingers); this.Controls.Add(pictureBoxEnglishSongs); diff --git a/PrimaryFormParts/SongSearch/PrimaryForm.SongSearch.NumberSearch.cs b/PrimaryFormParts/SongSearch/PrimaryForm.SongSearch.NumberSearch.cs index 64012c3..2ee4f21 100644 --- a/PrimaryFormParts/SongSearch/PrimaryForm.SongSearch.NumberSearch.cs +++ b/PrimaryFormParts/SongSearch/PrimaryForm.SongSearch.NumberSearch.cs @@ -1,312 +1,865 @@ using System; -using System.Drawing; -using System.IO; -using System.Linq; -using System.Windows.Forms; +using System.IO; +using System.Drawing; +using System.Drawing.Imaging; +using System.Linq; +using System.Windows.Forms; +using System.Collections.Generic; +using IniParser; +using IniParser.Model; +using System.Text; +/* + WordCountSongs -> SongIDSearch + WordCount -> SongID + numberWordCount -> numberSongID + NumberWordCount -> NumberSongID + inputBoxWordCountFontName -> inputBoxSongIDFontName + inputBoxWordCountFontSize -> inputBoxSongIDFontSize + inputBoxWordCountFontStyle -> inputBoxSongIDFontStyle + inputBoxWordCountForeColor -> inputBoxSongIDForeColor + LoadConfigDataforWordCountSongs -> LoadConfigDataforSongIDSearch + LoadButtonCoordinatesForWordCountSongs -> LoadButtonCoordinatesForSongIDSearch + LoadButtonImagesForWordCountSongs -> LoadButtonImagesForSongIDSearch + LoadSpecialButtonCoordinatesForWordCountSongs -> LoadSpecialButtonCoordinatesForSongIDSearch + RemoveWhiteBorderForWordCountSongs -> RemoveWhiteBorderForSongIDSearch + CreateSpecialButtonForWordCountSongs -> CreateSpecialButtonForSongIDSearch + LoadInputBoxConfigForWordCountSongs -> LoadInputBoxConfigForSongIDSearch +*/ + namespace DualScreenDemo { public partial class PrimaryForm { + private PictureBox pictureBoxSongIDSearch; + + private Button[] numberSongIDButtonsForSongs; + private Button modifyButtonSongIDSearch; + private Button clearButtonSongIDSearch; + private Button closeButtonSongIDSearch; + + private string[] numberSongIDSymbols; + private (int X, int Y, int Width, int Height)[] numberSongIDButtonCoords; + private Dictionary numberSongIDButtonImages; + + private (int X, int Y, int Width, int Height) modifyButtonSongIDCoords; + private (int X, int Y, int Width, int Height) clearButtonSongIDCoords; + private (int X, int Y, int Width, int Height) closeButtonSongIDCoords; + + private RichTextBox inputBoxSongIDSearch; + + private (int X, int Y, int Width, int Height) inputBoxSongIDCoords; + private string inputBoxSongIDFontName; + private float inputBoxSongIDFontSize; + private FontStyle inputBoxSongIDFontStyle; + private Color inputBoxSongIDForeColor; + /// - /// 「數字搜尋」按鈕點擊事件 - /// 1. 更新所有搜尋按鈕的背景圖片,使「數字搜尋」顯示為啟動狀態 - /// 2. 在 `pictureBoxSongIDSearch` 顯示對應的圖片 - /// 3. 顯示「數字搜尋」相關 UI 元素 + /// 點擊「注音歌手搜尋」按鈕時執行的事件處理函式。 + /// 此函式負責更新按鈕的背景圖片、載入對應的歌手圖片,並切換相關 UI 控件的可見性。 /// - private void NumberSearchButton2_Click(object sender, EventArgs e) + /// 觸發事件的物件(通常是按鈕本身)。 + /// 事件參數。 + private void SongIDSearchSongsButton_Click(object sender, EventArgs e) { - // 更新搜尋按鈕的背景圖片 (將所有按鈕設為未選中狀態,僅數字搜尋為選中狀態) - zhuyinSearchSongButton.BackgroundImage = zhuyinSearchSongNormalBackground; - englishSearchSongButton.BackgroundImage = englishSearchSongNormalBackground; - pinyinSearchSongButton.BackgroundImage = pinyinSearchSongNormalBackground; + // 設定按鈕背景,將「注音搜尋」設為啟動狀態,其餘按鈕恢復為正常狀態 + zhuyinSearchButton.BackgroundImage = zhuyinSearchActiveBackground; + englishSearchButton.BackgroundImage = englishSearchNormalBackground; + pinyinSearchButton.BackgroundImage = pinyinSearchNormalBackground; wordCountSearchSongButton.BackgroundImage = wordCountSearchSongNormalBackground; handWritingSearchSongButton.BackgroundImage = handWritingSearchNormalBackground; - numberSearchSongButton.BackgroundImage = numberSearchSongActiveBackground; // 設定數字搜尋為選中狀態 - // 在 `pictureBoxSongIDSearch` 顯示數字搜尋的 UI 圖片 - ShowImageOnPictureBoxSongIDSearch(Path.Combine(Application.StartupPath, @"themes\superstar\6-1.png")); + //SongIDSearchButton.BackgroundImage = SongIDSearchNormalBackground; - // 顯示與數字搜尋相關的 UI 元素 - SetPictureBoxSongIDSearchAndButtonsVisibility(true); + + // 載入設定檔,取得圖片路徑資訊 + var configData = LoadConfigDataforSongIDSearch(); + + // 取得「注音歌手圖片」的完整路徑 + string imagePath = Path.Combine(Application.StartupPath, configData["ImagePaths"]["SongIDSearch"]); + + // 在 PictureBox 中顯示對應的「注音歌手」圖片 + ShowImageOnPictureBoxSongIDSearch(Path.Combine(Application.StartupPath, imagePath)); + + // 設定不同搜尋模式的 UI 控件可見性 + SetEnglishSingersAndButtonsVisibility(false); // 隱藏英文字母搜尋相關控件 + SetPinYinSingersAndButtonsVisibility(false); // 隱藏拼音搜尋相關控件 + SetHandWritingForSingersAndButtonsVisibility(false); // 隱藏手寫搜尋相關控件 + SetPictureBoxArtistSearchAndButtonsVisibility(false); // 隱藏其他搜尋模式的圖片框 + + SetSongIDSearchAndButtonsVisibility(true); // 顯示字數搜尋相關控件 + // 顯示「注音歌手搜尋」的圖片框 pictureBoxSongIDSearch.Visible = true; } + /// - /// 在 pictureBoxSongIDSearch 中顯示指定路徑的圖片,並對其進行裁切與調整大小 - /// 1. 加載原始圖片 - /// 2. 裁切圖片以符合 UI 需求 - /// 3. 設定 pictureBoxSongIDSearch 的圖片 - /// 4. 調整 pictureBoxSongIDSearch 的位置與大小 - /// 5. 顯示 pictureBoxSongIDSearch + /// 從 config.ini 設定檔中載入注音符號(NumberWordCount Symbols)。 + /// 讀取 ini 檔的 [NumberWordCountSymbols] 區塊,並將「Symbols」欄位的值解析為陣列。 /// - /// 要顯示的圖片路徑 - private void ShowImageOnPictureBoxSongIDSearch(string imagePath) + private void LoadNumberSongIDSymbolsFromConfig() { - // 1. 加載原始圖片 - Bitmap originalImage = new Bitmap(imagePath); + // 建立 INI 檔案解析器 + var parser = new FileIniDataParser(); + + // 設定檔路徑 + string iniFilePath = "config.ini"; - // 2. 定義裁切區域 (左上角 x=593, y=135, 寬=507, 高=508) - Rectangle cropArea = new Rectangle(593, 135, 507, 508); + IniData data; - // 3. 進行圖片裁切 - Bitmap croppedImage = CropImage(originalImage, cropArea); + // 以 UTF-8 編碼開啟並讀取 INI 檔案 + using (var reader = new StreamReader(iniFilePath, Encoding.UTF8)) + { + // 解析 INI 檔內容 + data = parser.ReadData(reader); + } - // 4. 設定 `pictureBoxSongIDSearch` 的圖片 - pictureBoxSongIDSearch.Image = croppedImage; + // 取得 [NumberSongIDSymbols] 區塊中的 "Symbols" 欄位內容 + string symbols = data["NumberSongIDSymbols"]["Symbols"]; - // 5. 調整 `pictureBoxSongIDSearch` 的大小與位置 (基於 cropArea 並加上偏移量) - ResizeAndPositionPictureBox(pictureBoxSongIDSearch, cropArea.X + offsetXSongID, cropArea.Y + offsetYSongID, cropArea.Width, cropArea.Height); + // 將符號字串以逗號分隔,轉換為字串陣列 + numberSongIDSymbols = symbols.Split(','); + } - // 6. 顯示 `pictureBoxSongIDSearch` - pictureBoxSongIDSearch.Visible = true; + + /// + /// 從設定檔 (config.ini) 載入 INI 設定數據。 + /// + /// 回傳解析後的 INI 設定數據 (IniData)。 + private IniData LoadConfigDataforSongIDSearch() + { + var parser = new FileIniDataParser(); + string iniFilePath = "config.ini"; + + // 使用 UTF-8 讀取 INI 檔案並解析內容 + using (var reader = new StreamReader(iniFilePath, Encoding.UTF8)) + { + return parser.ReadData(reader); + } + } + + /// + /// 從 INI 設定數據中讀取注音符號 (NumberSongID Symbols)。 + /// + /// 已解析的 INI 設定數據。 + /// 回傳包含注音符號的字串陣列。 + private string[] LoadNumberSongIDSymbols(IniData data) + { + // 從 INI 檔案的 [NumberSongIDSymbols] 區塊取得 Symbols 欄位值 + string symbols = data["NumberSongIDSymbols"]["Symbols"]; + + // 以逗號分隔字串並轉換為字串陣列 + return symbols.Split(','); } /// - /// 當使用者點擊「修改按鈕」時,刪除 `inputBoxSongIDSearch` 輸入框內的最後一個字元。 + /// 從 INI 設定數據中載入按鈕座標資料。 /// - /// 觸發事件的對象(按鈕) + /// 已解析的 INI 設定數據。 + /// 設定檔中按鈕座標所屬的區塊名稱。 + /// 按鈕數量。 + /// 回傳包含按鈕座標的陣列,每個元素是由 (X, Y, Width, Height) 組成的元組。 + private (int X, int Y, int Width, int Height)[] LoadButtonCoordinatesForSongIDSearch(IniData data, string section, int buttonCount) + { + var buttonList = new List<(int X, int Y, int Width, int Height)>(); + + // 迴圈讀取每個按鈕的座標設定 + for (int i = 1; i <= buttonCount; i++) + { + // 取得按鈕座標的字串 (格式: X,Y,Width,Height) + var coordString = data[section][$"button{i}"]; + var coords = coordString.Split(','); + + // 將座標資料轉換為 (X, Y, Width, Height) 元組並加入清單 + buttonList.Add(( + int.Parse(coords[0]), // X 座標 + int.Parse(coords[1]), // Y 座標 + int.Parse(coords[2]), // 寬度 + int.Parse(coords[3]) // 高度 + )); + } + + // 回傳所有按鈕座標的陣列 + return buttonList.ToArray(); + } + + /// + /// 從 INI 設定數據中載入按鈕圖片檔案路徑資料 (包含正常、點擊、滑鼠移過圖片)。 + /// + /// 已解析的 INI 設定數據。 + /// 設定檔中按鈕圖片設定所屬的區塊名稱。 + /// 按鈕數量。 + /// 回傳一個字典,鍵是按鈕名稱,值是包含正常、點擊和滑鼠移過狀態的元組。 + private Dictionary LoadButtonImagesForSongIDSearch(IniData data, string section, int buttonCount) + { + var buttonImages = new Dictionary(); + + // 迴圈讀取每個按鈕的圖片設定 + for (int i = 0; i < 10; i++) + { + // 讀取按鈕的三種圖片狀態:正常、點擊、滑鼠移過 + buttonImages[$"button{i}"] = ( + data[section][$"button{i}_normal"], // 正常狀態圖片路徑 + data[section][$"button{i}_mouseDown"], // 點擊狀態圖片路徑 + data[section][$"button{i}_mouseOver"] // 滑鼠移過狀態圖片路徑 + ); + } + + // 回傳包含所有按鈕圖片路徑資料的字典 + return buttonImages; + } + + + /// + /// 從 INI 設定數據中載入特定按鈕的座標資料。 + /// + /// 已解析的 INI 設定數據。 + /// 設定檔中按鈕座標所屬的區塊名稱。 + /// 指定按鈕的鍵名 (如 "button1")。 + /// 回傳包含按鈕座標的元組 (X, Y, Width, Height)。 + private (int X, int Y, int Width, int Height) LoadSpecialButtonCoordinatesForSongIDSearch(IniData data, string section, string buttonKey) + { + // 取得按鈕座標的字串 (格式: X,Y,Width,Height) + var coords = data[section][buttonKey].Split(','); + + // 解析座標字串並回傳 (X, Y, Width, Height) 元組 + return (int.Parse(coords[0]), int.Parse(coords[1]), int.Parse(coords[2]), int.Parse(coords[3])); + } + + /// + /// 從 INI 設定數據中載入按鈕的圖片資料 (包含正常、點擊、滑鼠移過圖片)。 + /// + /// 已解析的 INI 設定數據。 + /// 設定檔中按鈕圖片設定所屬的區塊名稱。 + /// 回傳包含按鈕三種狀態圖片路徑的元組 (normal, mouseDown, mouseOver)。 + private (string normal, string mouseDown, string mouseOver) LoadButtonImagesForSongIDSearch(IniData data, string section) + { + // 讀取按鈕三種狀態的圖片路徑 + return ( + data[section]["normal"], // 正常狀態圖片路徑 + data[section]["mouseDown"], // 點擊狀態圖片路徑 + data[section]["mouseOver"] // 滑鼠移過狀態圖片路徑 + ); + } + + + /// + /// 初始化並設置語音按鈕的相關資料,包括符號、座標與圖片等。 + /// + private void InitializeNumberSongIDButtons() + { + // 載入配置資料 + var data = LoadConfigDataforSongIDSearch(); + + // 載入語音符號(如拼音、注音符號等) + numberSongIDSymbols = LoadNumberSongIDSymbols(data); + + // 載入按鈕座標資料 + numberSongIDButtonCoords = LoadButtonCoordinatesForSongIDSearch(data, "NumberSongIDButtonCoordinates", 10); + + // 載入按鈕圖片資料 + numberSongIDButtonImages = LoadButtonImagesForSongIDSearch(data, "NumberSongIDButtonImages", 10); + + // 初始化語音按鈕陣列,總共有 10 個按鈕 + numberSongIDButtonsForSongs = new Button[10]; + + // 設置每個語音按鈕 + for (int i = 0; i < 10; i++) + { + // 根據按鈕索引讀取其圖片資料 + var buttonImages = numberSongIDButtonImages[$"button{i}"]; + + // 創建並初始化語音按鈕,設定其背景圖片 + CreateNumberSongIDButton(i, buttonImages.normal, buttonImages.mouseDown, buttonImages.mouseOver); + } + } + + + /// + /// 創建一個語音按鈕,並為其設置圖片、座標、事件等屬性。 + /// + /// 按鈕的索引,用來獲取對應的語音符號、座標和圖片資料。 + /// 正常狀態下的圖片路徑。 + /// 點擊狀態下的圖片路徑。 + /// 滑鼠移過狀態下的圖片路徑。 + private void CreateNumberSongIDButton(int index, string normalImagePath, string mouseDownImagePath, string mouseOverImagePath) + { + try + { + // 創建語音按鈕並設置其屬性 + numberSongIDButtonsForSongs[index] = new Button + { + Name = $"numberSongIDButton_{numberSongIDSymbols[index]}", // 按鈕名稱設為語音符號名稱 + BackgroundImage = Image.FromFile(Path.Combine(Application.StartupPath, normalImagePath)), // 設定背景圖片 + BackgroundImageLayout = ImageLayout.Stretch, // 設定圖片拉伸樣式 + FlatStyle = FlatStyle.Flat, // 設定為平面風格 + FlatAppearance = { BorderSize = 0 } // 設定無邊框 + }; + + // 調整按鈕大小並設置位置 + ResizeAndPositionButton(numberSongIDButtonsForSongs[index], numberSongIDButtonCoords[index].X, numberSongIDButtonCoords[index].Y, + numberSongIDButtonCoords[index].Width, numberSongIDButtonCoords[index].Height); + + // 從檔案中讀取正常、點擊和滑鼠懸停狀態的圖片 + Image normalImage = Image.FromFile(Path.Combine(Application.StartupPath, normalImagePath)); + Image mouseDownImage = Image.FromFile(Path.Combine(Application.StartupPath, mouseDownImagePath)); + Image mouseOverImage = Image.FromFile(Path.Combine(Application.StartupPath, mouseOverImagePath)); + + // 設置滑鼠事件:點擊、進入、離開等,改變按鈕的背景圖片 + numberSongIDButtonsForSongs[index].MouseDown += (s, e) => numberSongIDButtonsForSongs[index].BackgroundImage = mouseDownImage; + numberSongIDButtonsForSongs[index].MouseUp += (s, e) => numberSongIDButtonsForSongs[index].BackgroundImage = normalImage; + numberSongIDButtonsForSongs[index].MouseEnter += (s, e) => numberSongIDButtonsForSongs[index].BackgroundImage = mouseOverImage; + numberSongIDButtonsForSongs[index].MouseLeave += (s, e) => numberSongIDButtonsForSongs[index].BackgroundImage = normalImage; + + // 設置點擊事件處理方法 + numberSongIDButtonsForSongs[index].Click += NumberSongIDButton_Click; + + // 設置按鈕的 Tag 屬性為對應的語音符號 + numberSongIDButtonsForSongs[index].Tag = numberSongIDSymbols[index]; + + // 將按鈕添加到表單的控制項集合中 + this.Controls.Add(numberSongIDButtonsForSongs[index]); + } + catch (Exception ex) + { + // 捕捉錯誤並輸出錯誤訊息 + Console.WriteLine($"Error creating button at index {index}: {ex.Message}"); + } + } + + + /// + /// 初始化所有與注音歌手相關的按鈕,包括語音符號按鈕、特殊按鈕及輸入框。 + /// + private void InitializeButtonsForSongIDSearch() + { + // 從配置檔案加載注音符號並初始化按鈕 + LoadNumberSongIDSymbolsFromConfig(); + + // 初始化所有語音按鈕 + InitializeNumberSongIDButtons(); + + // 初始化注音歌手的特殊按鈕(例如音量、搜尋等) + InitializeSpecialButtonsForSongIDSearch(); + + // 初始化注音歌手的輸入框 + InitializeInputBoxSongIDSearch(); + } + + + /// + /// 移除圖像周圍的白色邊框,將邊框的像素透明化。 + /// + /// 待處理的圖像文件路徑。 + /// 處理後的圖像,其中白色邊框已被去除並替換為透明。 + private Image RemoveWhiteBorderForSongIDSearch(string imagePath) + { + // 創建一個 Bitmap 物件來加載圖像 + Bitmap bmp = new Bitmap(imagePath); + + // 定義圖像的矩形區域,這是我們將要操作的區域 + Rectangle rect = new Rectangle(0, 0, bmp.Width, bmp.Height); + + // 鎖定圖像的位圖數據,以便進行直接修改 + BitmapData bmpData = bmp.LockBits(rect, ImageLockMode.ReadWrite, bmp.PixelFormat); + + IntPtr ptr = bmpData.Scan0; // 獲取位圖數據的起始位置 + int bytes = Math.Abs(bmpData.Stride) * bmp.Height; // 計算圖像的總字節數 + byte[] rgbValues = new byte[bytes]; // 用來存儲圖像的像素數據 + System.Runtime.InteropServices.Marshal.Copy(ptr, rgbValues, 0, bytes); // 從圖像數據中複製像素數據到 rgbValues 陣列 + + // 遍歷每個像素點,檢查是否為白色邊框 + for (int y = 0; y < bmp.Height; y++) + { + for (int x = 0; x < bmp.Width; x++) + { + int position = (y * bmpData.Stride) + (x * 4); // 計算當前像素的位址 + byte b = rgbValues[position]; // 藍色分量 + byte g = rgbValues[position + 1]; // 綠色分量 + byte r = rgbValues[position + 2]; // 紅色分量 + byte a = rgbValues[position + 3]; // alpha 分量(透明度) + + // 如果當前像素在圖像邊緣且為白色 (255, 255, 255),則將其設為透明 + if ((x < 5 || x > bmp.Width - 5 || y < 5 || y > bmp.Height - 5) && r == 255 && g == 255 && b == 255) + { + // 將白色像素的 RGB 設置為 255, 255, 255 且 alpha 設為 0 (透明) + rgbValues[position] = 255; + rgbValues[position + 1] = 255; + rgbValues[position + 2] = 255; + rgbValues[position + 3] = 0; // 透明 + } + } + } + + // 將修改後的像素數據重新複製回位圖數據 + System.Runtime.InteropServices.Marshal.Copy(rgbValues, 0, ptr, bytes); + + // 解鎖圖像數據 + bmp.UnlockBits(bmpData); + + // 返回處理後的圖像 + return bmp; + } + + + /// + /// 初始化與注音歌手相關的特殊按鈕,包括修改、清除和關閉按鈕。 + /// + private void InitializeSpecialButtonsForSongIDSearch() + { + // 初始化修改按鈕 + InitializeModifyButtonSongIDSearch(); + + // 初始化清除按鈕 + InitializeClearButtonSongIDSearch(); + + // 初始化關閉按鈕 + InitializeCloseButtonSongIDSearch(); + } + + + /// + /// 初始化「修改」按鈕,設定按鈕的坐標、圖片和點擊事件。 + /// + private void InitializeModifyButtonSongIDSearch() + { + // 加載配置數據 + var data = LoadConfigDataforSongIDSearch(); + + // 讀取按鈕坐標 + modifyButtonSongIDCoords = LoadSpecialButtonCoordinatesForSongIDSearch(data, "SpecialButtonCoordinates", "modifyButtonSongIDSearch"); + + // 加載按鈕圖片(正常、鼠標懸停、鼠標按下) + var buttonImages = LoadButtonImagesForSongIDSearch(data, "ModifyButtonImagesSongID"); + + // 創建「修改」按鈕,並設置坐標、圖片及點擊事件 + modifyButtonSongIDSearch = CreateSpecialButtonForSongIDSearch( + "btnModifySongIDSearch", // 按鈕名稱 + modifyButtonSongIDCoords, // 按鈕坐標 + buttonImages.normal, // 正常狀態圖片 + buttonImages.mouseOver, // 鼠標懸停圖片 + buttonImages.mouseDown, // 鼠標按下圖片 + ModifyButtonSongIDSearch_Click // 按鈕點擊事件 + ); + } + + /// + /// 處理「修改」按鈕的點擊事件,該事件會刪除輸入框中的最後一個字符。 + /// + /// 觸發事件的對象 /// 事件參數 private void ModifyButtonSongIDSearch_Click(object sender, EventArgs e) { - // 確保 `inputBoxSongIDSearch` 內有文字,避免 `Substring` 發生錯誤 - if (inputBoxSongIDSearch.Text.Length > 0) + // 如果輸入框不為空,且包含輸入內容,則刪除最後一個字符 + if (this.Controls.Contains(inputBoxSongIDSearch) && inputBoxSongIDSearch.Text.Length > 0) { - // 刪除輸入框內的最後一個字元 inputBoxSongIDSearch.Text = inputBoxSongIDSearch.Text.Substring(0, inputBoxSongIDSearch.Text.Length - 1); } } /// - /// 當使用者點擊「關閉按鈕」時,隱藏歌曲編號搜尋的相關 UI 元件。 + /// 初始化「清除」按鈕,設定按鈕的坐標、圖片和點擊事件。 /// - /// 觸發事件的對象(按鈕) - /// 事件參數 - private void CloseButtonSongIDSearch_Click(object sender, EventArgs e) + private void InitializeClearButtonSongIDSearch() { - // 隱藏歌曲編號搜尋的相關 UI 元件(包含輸入框、按鈕、圖片等) - SetPictureBoxSongIDSearchAndButtonsVisibility(false); + // 加載配置數據 + var data = LoadConfigDataforSongIDSearch(); + + // 讀取按鈕坐標 + clearButtonSongIDCoords = LoadSpecialButtonCoordinatesForSongIDSearch(data, "SpecialButtonCoordinates", "clearButtonSongIDSearch"); + + // 加載按鈕圖片(正常、鼠標懸停、鼠標按下) + var buttonImages = LoadButtonImagesForSongIDSearch(data, "ClearButtonImagesSongID"); + + // 創建「清除」按鈕,並設置坐標、圖片及點擊事件 + clearButtonSongIDSearch = CreateSpecialButtonForSongIDSearch( + "btnClearSongIDSearch", // 按鈕名稱 + clearButtonSongIDCoords, // 按鈕坐標 + buttonImages.normal, // 正常狀態圖片 + buttonImages.mouseOver, // 鼠標懸停圖片 + buttonImages.mouseDown, // 鼠標按下圖片 + ClearButtonSongIDSearch_Click // 按鈕點擊事件 + ); } /// - /// 控制歌曲編號搜尋的 UI 顯示與隱藏。 - /// true 時,顯示 UI 元件。 - /// false 時,隱藏 UI 元件。 + /// 處理「清除」按鈕的點擊事件,該事件會清空輸入框中的所有文本。 /// - /// 是否顯示 UI - private void SetPictureBoxSongIDSearchAndButtonsVisibility(bool isVisible) + /// 觸發事件的對象 + /// 事件參數 + private void ClearButtonSongIDSearch_Click(object sender, EventArgs e) { - // 定義 UI 更新的 Action - System.Action action = () => + // 如果輸入框不為空,則清空該框的文本內容 + if (this.Controls.Contains(inputBoxSongIDSearch) && inputBoxSongIDSearch.Text.Length > 0) { - // 暫停佈局更新,提高效能 - SuspendLayout(); + inputBoxSongIDSearch.Text = ""; + } + } - // 控制歌曲編號搜尋圖片的顯示/隱藏 - pictureBoxSongIDSearch.Visible = isVisible; - // 如果顯示圖片,則將其置頂 - if (isVisible) pictureBoxSongIDSearch.BringToFront(); + /// + /// 初始化「關閉」按鈕,設定按鈕的坐標、圖片和點擊事件。 + /// + private void InitializeCloseButtonSongIDSearch() + { + // 加載配置數據 + var data = LoadConfigDataforSongIDSearch(); - // 控制「修改」和「關閉」按鈕的可見性 - modifyButtonSongIDSearch.Visible = isVisible; - closeButtonSongIDSearch.Visible = isVisible; + // 讀取按鈕坐標 + closeButtonSongIDCoords = LoadSpecialButtonCoordinatesForSongIDSearch(data, "SpecialButtonCoordinates", "closeButtonSongIDSearch"); - // 如果按鈕顯示,則置頂 - if (isVisible) - { - modifyButtonSongIDSearch.BringToFront(); - closeButtonSongIDSearch.BringToFront(); - } + // 加載按鈕圖片(正常、鼠標懸停、鼠標按下) + var buttonImages = LoadButtonImagesForSongIDSearch(data, "CloseButtonImagesSongID"); - // 控制數字按鈕的可見性 - foreach (Button button in numberButtonsSongIDSearch) - { - button.Visible = isVisible; - - // 使按鈕顯示時位於最上層 - if (isVisible) - button.BringToFront(); - } + // 創建「關閉」按鈕,並設置坐標、圖片及點擊事件 + closeButtonSongIDSearch = CreateSpecialButtonForSongIDSearch( + "btnCloseSongIDSearch", // 按鈕名稱 + closeButtonSongIDCoords, // 按鈕坐標 + buttonImages.normal, // 正常狀態圖片 + buttonImages.mouseOver, // 鼠標懸停圖片 + buttonImages.mouseDown, // 鼠標按下圖片 + CloseButtonSongIDSearch_Click // 按鈕點擊事件 + ); + } - // 控制輸入框的可見性 - inputBoxSongIDSearch.Visible = isVisible; - if (isVisible) inputBoxSongIDSearch.BringToFront(); - // 恢復佈局更新 - ResumeLayout(); + /// + /// 「關閉」按鈕的點擊事件處理方法。 + /// 隱藏 SongID 歌手圖片框以及與其相關的按鈕。 + /// + /// 觸發事件的對象,這裡是關閉按鈕。 + /// 事件參數。 + private void CloseButtonSongIDSearch_Click(object sender, EventArgs e) + { + // 隱藏 SongID 歌手圖片框 + pictureBoxSongIDSearch.Visible = false; + + // 隱藏與 SongID 歌手相關的所有按鈕 + SetSongIDSearchAndButtonsVisibility(false); + } + + + /// + /// 創建一個特殊的按鈕,並設定其顯示屬性、事件處理和位置。 + /// + /// 按鈕的名稱。 + /// 按鈕的坐標和大小,包含 X, Y, 寬度和高度。 + /// 按鈕正常狀態下的背景圖片路徑。 + /// 鼠標懸停時按鈕的背景圖片路徑。 + /// 鼠標點擊時按鈕的背景圖片路徑。 + /// 按鈕的點擊事件處理程序。 + /// 創建並返回的按鈕對象。 + private Button CreateSpecialButtonForSongIDSearch(string name, (int X, int Y, int Width, int Height) coords, string normalImagePath, string mouseOverImagePath, string mouseDownImagePath, EventHandler clickEventHandler) + { + // 創建按鈕並設定基本屬性 + var button = new Button + { + Name = name, + FlatStyle = FlatStyle.Flat, + FlatAppearance = { BorderSize = 0, MouseDownBackColor = Color.Transparent, MouseOverBackColor = Color.Transparent }, + BackgroundImageLayout = ImageLayout.Stretch, + BackgroundImage = Image.FromFile(Path.Combine(Application.StartupPath, normalImagePath)) }; - // 如果當前執行緒不是 UI 執行緒,則使用 Invoke 呼叫 + // 設定按鈕的大小和位置 + ResizeAndPositionButton(button, coords.X, coords.Y, coords.Width, coords.Height); + + // 設定鼠標事件:進入、離開、按下、放開 + button.MouseEnter += (sender, e) => button.BackgroundImage = Image.FromFile(Path.Combine(Application.StartupPath, mouseOverImagePath)); + button.MouseLeave += (sender, e) => button.BackgroundImage = Image.FromFile(Path.Combine(Application.StartupPath, normalImagePath)); + button.MouseDown += (sender, e) => button.BackgroundImage = Image.FromFile(Path.Combine(Application.StartupPath, mouseDownImagePath)); + button.MouseUp += (sender, e) => button.BackgroundImage = Image.FromFile(Path.Combine(Application.StartupPath, normalImagePath)); + + // 註冊點擊事件處理 + button.Click += clickEventHandler; + + // 將按鈕添加到控件集合中 + this.Controls.Add(button); + + return button; + } + + + /// + /// 初始化 SongID 歌手的輸入框,並設定其屬性與事件處理程序。 + /// + private void InitializeInputBoxSongIDSearch() + { + try + { + // 加載輸入框配置 + LoadInputBoxConfigForSongIDSearch(); + + // 創建一個 RichTextBox 控件來作為輸入框 + inputBoxSongIDSearch = new RichTextBox + { + Name = "inputBoxSongIDSearch", + ForeColor = inputBoxSongIDForeColor, // 設定文字顏色 + Font = new Font(inputBoxSongIDFontName, inputBoxSongIDFontSize, inputBoxSongIDFontStyle), // 設定字體樣式 + ScrollBars = RichTextBoxScrollBars.None // 不顯示滾動條 + }; + + // 調整和定位輸入框的位置及大小 + ResizeAndPositionControl(inputBoxSongIDSearch, inputBoxSongIDCoords.X, inputBoxSongIDCoords.Y, inputBoxSongIDCoords.Width, inputBoxSongIDCoords.Height); + + // 設定文本變更事件,當輸入框內容改變時觸發 + inputBoxSongIDSearch.TextChanged += (sender, e) => + { + string searchText = inputBoxSongIDSearch.Text; // 取得輸入內容 + + // 根據輸入的注音篩選歌曲清單 + var searchResults = allSongs.Where(song => song.SongNumber.StartsWith(searchText)).ToList(); + + // 重置分頁 + currentPage = 0; + currentSongList = searchResults; + totalPages = (int)Math.Ceiling((double)searchResults.Count / itemsPerPage); + + // 更新多頁面面板的內容 + multiPagePanel.currentPageIndex = 0; + multiPagePanel.LoadSongs(currentSongList); + }; + + // 將輸入框加入到窗體的控件集合中 + this.Controls.Add(inputBoxSongIDSearch); + } + catch (Exception ex) + { + // 如果初始化過程中出現錯誤,則在控制台輸出錯誤信息 + Console.WriteLine("Error initializing inputBoxSongIDSearch: " + ex.Message); + } + } + + + /// + /// 從配置文件 `config.ini` 中加載輸入框的設置,包括位置、大小、字體等屬性。 + /// + private void LoadInputBoxConfigForSongIDSearch() + { + try + { + // 創建 INI 解析器 + var parser = new FileIniDataParser(); + string iniFilePath = "config.ini"; // 配置文件的路徑 + + IniData data; + // 打開並讀取配置文件 + using (var reader = new StreamReader(iniFilePath, Encoding.UTF8)) + { + data = parser.ReadData(reader); + } + + // 從配置中加載輸入框的坐標和大小 + inputBoxSongIDCoords = ( + int.Parse(data["InputBoxSongIDSearch"]["X"]), // 輸入框的 X 坐標 + int.Parse(data["InputBoxSongIDSearch"]["Y"]), // 輸入框的 Y 坐標 + int.Parse(data["InputBoxSongIDSearch"]["Width"]), // 輸入框的寬度 + int.Parse(data["InputBoxSongIDSearch"]["Height"]) // 輸入框的高度 + ); + + // 從配置中加載字體屬性 + inputBoxSongIDFontName = data["InputBoxSongIDSearch"]["FontName"]; // 字體名稱 + inputBoxSongIDFontSize = float.Parse(data["InputBoxSongIDSearch"]["FontSize"]); // 字體大小 + inputBoxSongIDFontStyle = (FontStyle)Enum.Parse(typeof(FontStyle), data["InputBoxSongIDSearch"]["FontStyle"]); // 字體樣式 + inputBoxSongIDForeColor = Color.FromName(data["InputBoxSongIDSearch"]["ForeColor"]); // 字體顏色 + + } + catch (Exception ex) + { + // 若發生錯誤,顯示錯誤信息 + Console.WriteLine("Error loading inputBox configuration: " + ex.Message); + } + } + + + /// + /// 存儲 `pictureBoxSongIDSearch` 控制項的坐標和大小設置。 + /// + /// + /// 這個元組包含了 `X`、`Y` 坐標以及 `Width`、`Height` 大小,用於配置 `pictureBoxSongIDSearch` 的位置和大小。 + /// + private (int X, int Y, int Width, int Height) pictureBoxSongIDSongCoords; + + /// + /// 從配置檔案中讀取 `PictureBoxSongIDSearch` 控制項的坐標和大小設置。 + /// + private void LoadPictureBoxSongIDSongCoordsFromConfig() + { + var parser = new FileIniDataParser(); + IniData data = parser.ReadFile("config.ini"); + + var coords = data["PictureBoxSongIDSearch"]; + pictureBoxSongIDSongCoords = ( + int.Parse(coords["X"]), + int.Parse(coords["Y"]), + int.Parse(coords["Width"]), + int.Parse(coords["Height"]) + ); + } + + + /// + /// 顯示圖片並根據配置文件設置顯示區域的大小和位置。 + /// + /// 圖片的路徑。 + private void ShowImageOnPictureBoxSongIDSearch(string imagePath) + { + // 讀取配置文件中的顯示區域設置 + LoadPictureBoxSongIDSongCoordsFromConfig(); + + // 加載原始圖片 + Bitmap originalImage = new Bitmap(imagePath); + + // 創建顯示區域,根據配置文件中的坐標和大小設置 + Rectangle displayArea = new Rectangle(pictureBoxSongIDSongCoords.X, pictureBoxSongIDSongCoords.Y, pictureBoxSongIDSongCoords.Width, pictureBoxSongIDSongCoords.Height); + + // 設置圖片到 PictureBox + pictureBoxSongIDSearch.Image = originalImage; + + // 調整 PictureBox 大小和位置 + ResizeAndPositionPictureBox(pictureBoxSongIDSearch, displayArea.X, displayArea.Y, displayArea.Width, displayArea.Height); + + // 顯示圖片 + pictureBoxSongIDSearch.Visible = true; + } + + + /// + /// 設置注音歌手相關控制項(包括圖片框、按鈕和輸入框)的顯示或隱藏狀態。 + /// + /// 指定控件是否可見。True 為顯示,False 為隱藏。 + private void SetSongIDSearchAndButtonsVisibility(bool isVisible) + { + // 定義一個動作來處理控制項的顯示或隱藏 + System.Action action = () => + { + try + { + // 暫停控制項佈局的重新排版,提高效率 + SuspendLayout(); + + // 檢查並設置圖片框的可見性 + if (pictureBoxSongIDSearch == null) + { + Console.WriteLine("pictureBoxSongIDSearch is null"); + } + else + { + pictureBoxSongIDSearch.Visible = isVisible; + if (isVisible) pictureBoxSongIDSearch.BringToFront(); // 如果顯示,將其置於最前 + } + + // 檢查並設置拼音按鈕的可見性 + if (numberSongIDButtonsForSongs == null) + { + Console.WriteLine("numberSongIDButtonsForSongs is null"); + } + else + { + foreach (var button in numberSongIDButtonsForSongs) + { + if (button == null) + { + Console.WriteLine("One of the numberSongIDButtonsForSongs is null"); + } + else + { + button.Visible = isVisible; + if (isVisible) button.BringToFront(); // 如果顯示,將其置於最前 + } + } + } + + // 檢查並設置修改按鈕的可見性 + if (modifyButtonSongIDSearch == null) + { + Console.WriteLine("modifyButtonSongIDSearch is null"); + } + else + { + modifyButtonSongIDSearch.Visible = isVisible; + if (isVisible) modifyButtonSongIDSearch.BringToFront(); // 如果顯示,將其置於最前 + } + + // 檢查並設置清除按鈕的可見性 + if (clearButtonSongIDSearch == null) + { + Console.WriteLine("clearButtonSongIDSearch is null"); + } + else + { + clearButtonSongIDSearch.Visible = isVisible; + if (isVisible) clearButtonSongIDSearch.BringToFront(); // 如果顯示,將其置於最前 + } + + // 檢查並設置關閉按鈕的可見性 + if (closeButtonSongIDSearch == null) + { + Console.WriteLine("closeButtonSongIDSearch is null"); + } + else + { + closeButtonSongIDSearch.Visible = isVisible; + if (isVisible) closeButtonSongIDSearch.BringToFront(); // 如果顯示,將其置於最前 + } + + // 檢查並設置輸入框的可見性 + if (inputBoxSongIDSearch == null) + { + Console.WriteLine("inputBoxSongIDSearch is null"); + } + else + { + inputBoxSongIDSearch.Visible = isVisible; + if (isVisible) inputBoxSongIDSearch.BringToFront(); // 如果顯示,將其置於最前 + } + + // 恢復控制項的佈局重新排版 + ResumeLayout(); + PerformLayout(); + + // 刷新所有控制項的顯示 + pictureBoxSongIDSearch?.Refresh(); + if (numberSongIDButtonsForSongs != null) + { + foreach (var button in numberSongIDButtonsForSongs) + { + button?.Refresh(); // 刷新每個按鈕 + } + } + modifyButtonSongIDSearch?.Refresh(); + clearButtonSongIDSearch?.Refresh(); + closeButtonSongIDSearch?.Refresh(); + inputBoxSongIDSearch?.Refresh(); + } + catch (Exception ex) + { + Console.WriteLine("Error in SetSongIDSearchAndButtonsVisibility: " + ex.Message); + } + }; + + // 檢查是否需要在主執行緒外執行 if (this.InvokeRequired) { - this.Invoke(action); + this.Invoke(action); // 如果需要,透過主執行緒執行 } else { - action(); + action(); // 否則直接執行 } } - - - /// - /// 初始化數字輸入 (Song ID Search) 相關按鈕與輸入框。 - /// 這些按鈕用於數字輸入、刪除 (Modify) 及關閉 (Close) 功能。 - /// - private void InitializeButtonsForPictureBoxSongIDSearch() + private void NumberSongIDButton_Click(object sender, EventArgs e) { - // 數字按鈕的座標陣列 (左上角 X, 左上角 Y, 右下角 X, 右下角 Y) - int[,] coords = new int[,] - { - {651, 292, 752, 400}, // 1 - {760, 292, 861, 400}, // 2 - {869, 292, 972, 399}, // 3 - {652, 401, 752, 502}, // 4 - {760, 401, 861, 504}, // 5 - {869, 398, 972, 502}, // 6 - {651, 502, 753, 607}, // 7 - {759, 504, 863, 607}, // 8 - {869, 503, 973, 608}, // 9 - {981, 501, 1083, 609} // 0 - }; - - // 取得螢幕的解析度 - int screenW = Screen.PrimaryScreen.Bounds.Width; - int screenH = Screen.PrimaryScreen.Bounds.Height; - - // 計算畫面縮放比例 - float widthRatio = screenW / (float)1920; - float heightRatio = screenH / (float)900; - - // 初始化數字按鈕陣列 - numberButtonsSongIDSearch = new Button[10]; - - // 建立數字按鈕 - for (int i = 0; i < numberButtonsSongIDSearch.Length; i++) - { - numberButtonsSongIDSearch[i] = new Button(); - - // 設定按鈕大小與位置 - ConfigureButton( - numberButtonsSongIDSearch[i], - coords[i, 0], // X 座標 - coords[i, 1], // Y 座標 - coords[i, 2] - coords[i, 0], // 按鈕寬度 - coords[i, 3] - coords[i, 1], // 按鈕高度 - resizedNormalStateImageFor6_1, // 一般狀態圖片 - resizedMouseOverImageFor6_1, // 滑鼠懸停圖片 - resizedMouseDownImageFor6_1, // 按下時圖片 - null - ); - - // 重新計算按鈕位置,確保適應不同解析度 - int newXForSongID = (int)(((numberButtonsSongIDSearch[i].Location.X / widthRatio) + offsetXSongID) * widthRatio); - int newYForSongID = (int)(((numberButtonsSongIDSearch[i].Location.Y / heightRatio) + offsetYSongID) * heightRatio); - numberButtonsSongIDSearch[i].Location = new Point(newXForSongID, newYForSongID); - - // 設定按鈕名稱與 Tag (數字值) - numberButtonsSongIDSearch[i].Name = "NumberButtonSongIDSearch" + i; - numberButtonsSongIDSearch[i].Tag = (i + 1).ToString(); - if (i == 9) // 最後一個按鈕 (實際上應為數字 "0") - { - numberButtonsSongIDSearch[i].Name = "NumberButtonSongIDSearch0"; - numberButtonsSongIDSearch[i].Tag = "0"; - } - - // 設定按鈕的點擊事件 - numberButtonsSongIDSearch[i].Click += SongIDSearchButton_Click; - - // 加入畫面 - this.Controls.Add(numberButtonsSongIDSearch[i]); - } - - // 初始化「刪除」按鈕 (Modify) - modifyButtonSongIDSearch = new Button - { - Name = "ModifyButtonSongIDSearch", - Tag = "Modify", - Visible = false - }; - - ConfigureButton(modifyButtonSongIDSearch, 978, 292, 1081 - 978, 397 - 292, - resizedNormalStateImageFor6_1, resizedMouseOverImageFor6_1, resizedMouseDownImageFor6_1, ModifyButtonSongIDSearch_Click); - - // 調整刪除按鈕位置以適應不同解析度 - int newX = (int)(((modifyButtonSongIDSearch.Location.X / widthRatio) + offsetXSongID) * widthRatio); - int newY = (int)(((modifyButtonSongIDSearch.Location.Y / heightRatio) + offsetYSongID) * heightRatio); - modifyButtonSongIDSearch.Location = new Point(newX, newY); - - this.Controls.Add(modifyButtonSongIDSearch); - - // 初始化「關閉」按鈕 (Close) - closeButtonSongIDSearch = new Button - { - Name = "CloseButtonSongIDSearch", - Tag = "Close", - Visible = false - }; - - ConfigureButton(closeButtonSongIDSearch, 982, 147, 1082 - 982, 250 - 147, - resizedNormalStateImageFor6_1, resizedMouseOverImageFor6_1, resizedMouseDownImageFor6_1, CloseButtonSongIDSearch_Click); - - // 調整關閉按鈕位置以適應不同解析度 - newX = (int)(((closeButtonSongIDSearch.Location.X / widthRatio) + offsetXSongID) * widthRatio); - newY = (int)(((closeButtonSongIDSearch.Location.Y / heightRatio) + offsetYSongID) * heightRatio); - closeButtonSongIDSearch.Location = new Point(newX, newY); - - this.Controls.Add(closeButtonSongIDSearch); - - // 初始化輸入框 (RichTextBox) - inputBoxSongIDSearch = new RichTextBox - { - Name = "inputBoxSongIDSearch", - ForeColor = Color.Black, - Font = new Font("細明體", (float)26 / 900 * Screen.PrimaryScreen.Bounds.Height, FontStyle.Regular) - }; - - // 調整輸入框大小與位置 - ResizeAndPositionControl(inputBoxSongIDSearch, 645 + offsetXSongID, 197 + offsetXSongID, 986 - 645, 281 - 197); - - // 當輸入框內容改變時,自動搜尋歌曲 - inputBoxSongIDSearch.TextChanged += (sender, e) => - { - string searchText = inputBoxSongIDSearch.Text; - - // 使用 LINQ 搜尋符合條件的歌曲 (以輸入的數字開頭) - var searchResults = allSongs.Where(song => song.SongNumber.StartsWith(searchText)).ToList(); - - // 重設分頁與歌曲列表 - currentPage = 0; - currentSongList = searchResults; - totalPages = (int)Math.Ceiling((double)searchResults.Count / itemsPerPage); - - // 更新歌曲顯示 - multiPagePanel.currentPageIndex = 0; - multiPagePanel.LoadSongs(currentSongList); - }; - - this.Controls.Add(inputBoxSongIDSearch); - } - - - - /// - /// 數字按鈕點擊事件,將按鈕上的數字 (Tag 值) 加入到 inputBoxSongIDSearch 中。 - /// - /// 觸發事件的按鈕 - /// 事件參數 - private void SongIDSearchButton_Click(object sender, EventArgs e) - { - // 嘗試將 sender 轉型為 Button var button = sender as Button; - - // 確保按鈕不為 null 且具有 Tag 屬性 (Tag 屬性存放數字) if (button != null && button.Tag != null) { - // 將按鈕的 Tag 值 (數字) 加入到輸入框 - inputBoxSongIDSearch.Text += button.Tag.ToString(); + + if (inputBoxSongIDSearch.Visible) + { + inputBoxSongIDSearch.Text += button.Tag.ToString(); + } } } diff --git a/PrimaryFormParts/SongSearch/PrimaryForm.SongSearch.WordCountSearch.cs b/PrimaryFormParts/SongSearch/PrimaryForm.SongSearch.WordCountSearch.cs index e8d7b13..ae68dd9 100644 --- a/PrimaryFormParts/SongSearch/PrimaryForm.SongSearch.WordCountSearch.cs +++ b/PrimaryFormParts/SongSearch/PrimaryForm.SongSearch.WordCountSearch.cs @@ -1,244 +1,869 @@ using System; -using System.Drawing; -using System.Linq; -using System.Windows.Forms; using System.IO; +using System.Drawing; +using System.Drawing.Imaging; +using System.Linq; +using System.Windows.Forms; +using System.Collections.Generic; +using IniParser; +using IniParser.Model; +using System.Text; +/* + ZhuYinSingers -> WordCountSongs + ZhuYin -> WordCount + phonetic -> numberWordCount + Phonetic -> NumberWordCount + inputBoxFontName -> inputBoxWordCountFontName + inputBoxFontSize -> inputBoxWordCountFontSize + inputBoxFontStyle -> inputBoxWordCountFontStyle + inputBoxForeColor -> inputBoxWordCountForeColor + LoadConfigData -> LoadConfigDataforWordCountSongs + LoadButtonCoordinates -> LoadButtonCoordinatesForWordCountSongs + LoadButtonImages -> LoadButtonImagesForWordCountSongs + LoadSpecialButtonCoordinates -> LoadSpecialButtonCoordinatesForWordCountSongs + RemoveWhiteBorder -> RemoveWhiteBorderForWordCountSongs + CreateSpecialButton -> CreateSpecialButtonForWordCountSongs + LoadInputBoxConfig -> LoadInputBoxConfigForWordCountSongs +*/ + namespace DualScreenDemo { public partial class PrimaryForm { + private PictureBox pictureBoxWordCountSongs; + + private Button[] numberWordCountButtonsForSongs; + private Button modifyButtonWordCountSongs; + private Button clearButtonWordCountSongs; + private Button closeButtonWordCountSongs; + + private string[] numberWordCountSymbols; + private (int X, int Y, int Width, int Height)[] numberWordCountButtonCoords; + private Dictionary numberWordCountButtonImages; + + private (int X, int Y, int Width, int Height) modifyButtonWordCountCoords; + private (int X, int Y, int Width, int Height) clearButtonWordCountCoords; + private (int X, int Y, int Width, int Height) closeButtonWordCountCoords; + + private RichTextBox inputBoxWordCountSongs; + + private (int X, int Y, int Width, int Height) inputBoxWordCountCoords; + private string inputBoxWordCountFontName; + private float inputBoxWordCountFontSize; + private FontStyle inputBoxWordCountFontStyle; + private Color inputBoxWordCountForeColor; + /// - /// 當使用者點擊「詞數查歌」按鈕時,切換到詞數查歌模式,更新 UI 並顯示對應的查歌界面。 + /// 點擊「注音歌手搜尋」按鈕時執行的事件處理函式。 + /// 此函式負責更新按鈕的背景圖片、載入對應的歌手圖片,並切換相關 UI 控件的可見性。 /// - /// 觸發事件的按鈕。 + /// 觸發事件的物件(通常是按鈕本身)。 /// 事件參數。 - private void WordCountSearchSong_Click(object sender, EventArgs e) - { - // 設定查歌模式按鈕的背景圖片 - zhuyinSearchSongButton.BackgroundImage = zhuyinSearchSongNormalBackground; // 注音查歌(普通狀態) - englishSearchSongButton.BackgroundImage = englishSearchSongNormalBackground; // 英文查歌(普通狀態) - pinyinSearchSongButton.BackgroundImage = pinyinSearchSongNormalBackground; // 拼音查歌(普通狀態) - wordCountSearchSongButton.BackgroundImage = wordCountSearchSongActiveBackground; // 詞數查歌(選中狀態) - handWritingSearchSongButton.BackgroundImage = handWritingSearchNormalBackground; // 手寫查歌(普通狀態) - numberSearchSongButton.BackgroundImage = numberSearchSongNormalBackground; // 數字查歌(普通狀態) - - // 顯示詞數查歌對應的圖片 - ShowImageOnPictureBoxWordCount(Path.Combine(Application.StartupPath, @"themes\superstar\6-1.png")); - - // 設定詞數查歌的 PictureBox 和按鈕的可見性 - SetPictureBoxWordCountAndButtonsVisibility(true); - pictureBoxWordCount.Visible = true; // 顯示 PictureBoxWordCount - - } - /// - /// 顯示詞數查歌對應的圖片 - /// - /// 圖片路徑 - private void ShowImageOnPictureBoxWordCount(string imagePath) + private void WordCountSearchSongsButton_Click(object sender, EventArgs e) { + // 設定按鈕背景,將「注音搜尋」設為啟動狀態,其餘按鈕恢復為正常狀態 + zhuyinSearchButton.BackgroundImage = zhuyinSearchActiveBackground; + englishSearchButton.BackgroundImage = englishSearchNormalBackground; + pinyinSearchButton.BackgroundImage = pinyinSearchNormalBackground; + wordCountSearchButton.BackgroundImage = wordCountSearchNormalBackground; + handWritingSearchButton.BackgroundImage = handWritingSearchNormalBackground; + + // 載入設定檔,取得圖片路徑資訊 + var configData = LoadConfigDataforWordCountSongs(); - // 載入原始圖片 - Bitmap originalImage = new Bitmap(imagePath); + // 取得「注音歌手圖片」的完整路徑 + string imagePath = Path.Combine(Application.StartupPath, configData["ImagePaths"]["WordCountSongs"]); - // 定義裁切區域 (起始座標: 593, 135,寬度: 507,高度: 508) - Rectangle cropArea = new Rectangle(593, 135, 507, 508); + // 在 PictureBox 中顯示對應的「注音歌手」圖片 + ShowImageOnPictureBoxWordCountSongs(Path.Combine(Application.StartupPath, imagePath)); - // 裁切圖片,獲得指定範圍的影像 - Bitmap croppedImage = CropImage(originalImage, cropArea); - - // 將裁切後的圖片顯示在 pictureBoxWordCount 上 - pictureBoxWordCount.Image = croppedImage; - - // 調整 pictureBoxWordCount 的大小與位置 - ResizeAndPositionPictureBox(pictureBoxWordCount, - cropArea.X + offsetXWordCount, // X 座標 (包含位移量) - cropArea.Y + offsetYWordCount, // Y 座標 (包含位移量) - cropArea.Width, // 寬度 - cropArea.Height // 高度 - ); - - // 顯示 pictureBoxWordCount - pictureBoxWordCount.Visible = true; + // 設定不同搜尋模式的 UI 控件可見性 + SetEnglishSingersAndButtonsVisibility(false); // 隱藏英文字母搜尋相關控件 + SetPinYinSingersAndButtonsVisibility(false); // 隱藏拼音搜尋相關控件 + SetHandWritingForSingersAndButtonsVisibility(false); // 隱藏手寫搜尋相關控件 + SetPictureBoxArtistSearchAndButtonsVisibility(false); // 隱藏其他搜尋模式的圖片框 + SetWordCountSongsAndButtonsVisibility(true); // 顯示字數搜尋相關控件 + // 顯示「注音歌手搜尋」的圖片框 + pictureBoxWordCountSongs.Visible = true; } - /// - /// 初始化「詞數查歌」模式的按鈕與輸入框,並根據螢幕解析度進行調整。 - /// - private void InitializeButtonsForPictureBoxWordCount() + + /// + /// 從 config.ini 設定檔中載入注音符號(NumberWordCount Symbols)。 + /// 讀取 ini 檔的 [NumberWordCountSymbols] 區塊,並將「Symbols」欄位的值解析為陣列。 + /// + private void LoadNumberWordCountSymbolsFromConfig() + { + // 建立 INI 檔案解析器 + var parser = new FileIniDataParser(); + + // 設定檔路徑 + string iniFilePath = "config.ini"; + + IniData data; + + // 以 UTF-8 編碼開啟並讀取 INI 檔案 + using (var reader = new StreamReader(iniFilePath, Encoding.UTF8)) { - // 定義數字按鈕的座標範圍 (左上角 X, Y 以及右下角 X, Y) - int[,] coords = new int[,] + // 解析 INI 檔內容 + data = parser.ReadData(reader); + } + + // 取得 [NumberWordCountSymbols] 區塊中的 "Symbols" 欄位內容 + string symbols = data["NumberWordCountSymbols"]["Symbols"]; + + // 將符號字串以逗號分隔,轉換為字串陣列 + numberWordCountSymbols = symbols.Split(','); + } + + + /// + /// 從設定檔 (config.ini) 載入 INI 設定數據。 + /// + /// 回傳解析後的 INI 設定數據 (IniData)。 + private IniData LoadConfigDataforWordCountSongs() + { + var parser = new FileIniDataParser(); + string iniFilePath = "config.ini"; + + // 使用 UTF-8 讀取 INI 檔案並解析內容 + using (var reader = new StreamReader(iniFilePath, Encoding.UTF8)) + { + return parser.ReadData(reader); + } + } + + /// + /// 從 INI 設定數據中讀取注音符號 (NumberWordCount Symbols)。 + /// + /// 已解析的 INI 設定數據。 + /// 回傳包含注音符號的字串陣列。 + private string[] LoadNumberWordCountSymbols(IniData data) + { + // 從 INI 檔案的 [NumberWordCountSymbols] 區塊取得 Symbols 欄位值 + string symbols = data["NumberWordCountSymbols"]["Symbols"]; + + // 以逗號分隔字串並轉換為字串陣列 + return symbols.Split(','); + } + + + /// + /// 從 INI 設定數據中載入按鈕座標資料。 + /// + /// 已解析的 INI 設定數據。 + /// 設定檔中按鈕座標所屬的區塊名稱。 + /// 按鈕數量。 + /// 回傳包含按鈕座標的陣列,每個元素是由 (X, Y, Width, Height) 組成的元組。 + private (int X, int Y, int Width, int Height)[] LoadButtonCoordinatesForWordCountSongs(IniData data, string section, int buttonCount) + { + var buttonList = new List<(int X, int Y, int Width, int Height)>(); + + // 迴圈讀取每個按鈕的座標設定 + for (int i = 1; i <= buttonCount; i++) + { + // 取得按鈕座標的字串 (格式: X,Y,Width,Height) + var coordString = data[section][$"button{i}"]; + var coords = coordString.Split(','); + + // 將座標資料轉換為 (X, Y, Width, Height) 元組並加入清單 + buttonList.Add(( + int.Parse(coords[0]), // X 座標 + int.Parse(coords[1]), // Y 座標 + int.Parse(coords[2]), // 寬度 + int.Parse(coords[3]) // 高度 + )); + } + + // 回傳所有按鈕座標的陣列 + return buttonList.ToArray(); + } + + /// + /// 從 INI 設定數據中載入按鈕圖片檔案路徑資料 (包含正常、點擊、滑鼠移過圖片)。 + /// + /// 已解析的 INI 設定數據。 + /// 設定檔中按鈕圖片設定所屬的區塊名稱。 + /// 按鈕數量。 + /// 回傳一個字典,鍵是按鈕名稱,值是包含正常、點擊和滑鼠移過狀態的元組。 + private Dictionary LoadButtonImagesForWordCountSongs(IniData data, string section, int buttonCount) + { + var buttonImages = new Dictionary(); + + // 迴圈讀取每個按鈕的圖片設定 + for (int i = 0; i < 10; i++) + { + // 讀取按鈕的三種圖片狀態:正常、點擊、滑鼠移過 + buttonImages[$"button{i}"] = ( + data[section][$"button{i}_normal"], // 正常狀態圖片路徑 + data[section][$"button{i}_mouseDown"], // 點擊狀態圖片路徑 + data[section][$"button{i}_mouseOver"] // 滑鼠移過狀態圖片路徑 + ); + } + + // 回傳包含所有按鈕圖片路徑資料的字典 + return buttonImages; + } + + + /// + /// 從 INI 設定數據中載入特定按鈕的座標資料。 + /// + /// 已解析的 INI 設定數據。 + /// 設定檔中按鈕座標所屬的區塊名稱。 + /// 指定按鈕的鍵名 (如 "button1")。 + /// 回傳包含按鈕座標的元組 (X, Y, Width, Height)。 + private (int X, int Y, int Width, int Height) LoadSpecialButtonCoordinatesForWordCountSongs(IniData data, string section, string buttonKey) + { + // 取得按鈕座標的字串 (格式: X,Y,Width,Height) + var coords = data[section][buttonKey].Split(','); + + // 解析座標字串並回傳 (X, Y, Width, Height) 元組 + return (int.Parse(coords[0]), int.Parse(coords[1]), int.Parse(coords[2]), int.Parse(coords[3])); + } + + /// + /// 從 INI 設定數據中載入按鈕的圖片資料 (包含正常、點擊、滑鼠移過圖片)。 + /// + /// 已解析的 INI 設定數據。 + /// 設定檔中按鈕圖片設定所屬的區塊名稱。 + /// 回傳包含按鈕三種狀態圖片路徑的元組 (normal, mouseDown, mouseOver)。 + private (string normal, string mouseDown, string mouseOver) LoadButtonImagesForWordCountSongs(IniData data, string section) + { + // 讀取按鈕三種狀態的圖片路徑 + return ( + data[section]["normal"], // 正常狀態圖片路徑 + data[section]["mouseDown"], // 點擊狀態圖片路徑 + data[section]["mouseOver"] // 滑鼠移過狀態圖片路徑 + ); + } + + + /// + /// 初始化並設置語音按鈕的相關資料,包括符號、座標與圖片等。 + /// + private void InitializeNumberWordCountButtons() + { + // 載入配置資料 + var data = LoadConfigDataforWordCountSongs(); + + // 載入語音符號(如拼音、注音符號等) + numberWordCountSymbols = LoadNumberWordCountSymbols(data); + + // 載入按鈕座標資料 + numberWordCountButtonCoords = LoadButtonCoordinatesForWordCountSongs(data, "NumberWordCountButtonCoordinates", 10); + + // 載入按鈕圖片資料 + numberWordCountButtonImages = LoadButtonImagesForWordCountSongs(data, "NumberWordCountButtonImages", 10); + + // 初始化語音按鈕陣列,總共有 10 個按鈕 + numberWordCountButtonsForSongs = new Button[10]; + + // 設置每個語音按鈕 + for (int i = 0; i < 10; i++) + { + // 根據按鈕索引讀取其圖片資料 + var buttonImages = numberWordCountButtonImages[$"button{i}"]; + + // 創建並初始化語音按鈕,設定其背景圖片 + CreateNumberWordCountButton(i, buttonImages.normal, buttonImages.mouseDown, buttonImages.mouseOver); + } + } + + + /// + /// 創建一個語音按鈕,並為其設置圖片、座標、事件等屬性。 + /// + /// 按鈕的索引,用來獲取對應的語音符號、座標和圖片資料。 + /// 正常狀態下的圖片路徑。 + /// 點擊狀態下的圖片路徑。 + /// 滑鼠移過狀態下的圖片路徑。 + private void CreateNumberWordCountButton(int index, string normalImagePath, string mouseDownImagePath, string mouseOverImagePath) + { + try + { + // 創建語音按鈕並設置其屬性 + numberWordCountButtonsForSongs[index] = new Button { - {651, 292, 752, 400}, // 1 - {760, 292, 861, 400}, // 2 - {869, 292, 972, 399}, // 3 - {652, 401, 752, 502}, // 4 - {760, 401, 861, 504}, // 5 - {869, 398, 972, 502}, // 6 - {651, 502, 753, 607}, // 7 - {759, 504, 863, 607}, // 8 - {869, 503, 973, 608}, // 9 - {981, 501, 1083, 609} // 0 + Name = $"numberWordCountButton_{numberWordCountSymbols[index]}", // 按鈕名稱設為語音符號名稱 + BackgroundImage = Image.FromFile(Path.Combine(Application.StartupPath, normalImagePath)), // 設定背景圖片 + BackgroundImageLayout = ImageLayout.Stretch, // 設定圖片拉伸樣式 + FlatStyle = FlatStyle.Flat, // 設定為平面風格 + FlatAppearance = { BorderSize = 0 } // 設定無邊框 }; - // 取得螢幕解析度 - int screenW = Screen.PrimaryScreen.Bounds.Width; - int screenH = Screen.PrimaryScreen.Bounds.Height; + // 調整按鈕大小並設置位置 + ResizeAndPositionButton(numberWordCountButtonsForSongs[index], numberWordCountButtonCoords[index].X, numberWordCountButtonCoords[index].Y, + numberWordCountButtonCoords[index].Width, numberWordCountButtonCoords[index].Height); - // 計算寬高比例,供座標縮放使用 - float widthRatio = screenW / (float)1440; - float heightRatio = screenH / (float)900; + // 從檔案中讀取正常、點擊和滑鼠懸停狀態的圖片 + Image normalImage = Image.FromFile(Path.Combine(Application.StartupPath, normalImagePath)); + Image mouseDownImage = Image.FromFile(Path.Combine(Application.StartupPath, mouseDownImagePath)); + Image mouseOverImage = Image.FromFile(Path.Combine(Application.StartupPath, mouseOverImagePath)); - // 建立數字按鈕陣列 - numberButtonsWordCount = new Button[10]; + // 設置滑鼠事件:點擊、進入、離開等,改變按鈕的背景圖片 + numberWordCountButtonsForSongs[index].MouseDown += (s, e) => numberWordCountButtonsForSongs[index].BackgroundImage = mouseDownImage; + numberWordCountButtonsForSongs[index].MouseUp += (s, e) => numberWordCountButtonsForSongs[index].BackgroundImage = normalImage; + numberWordCountButtonsForSongs[index].MouseEnter += (s, e) => numberWordCountButtonsForSongs[index].BackgroundImage = mouseOverImage; + numberWordCountButtonsForSongs[index].MouseLeave += (s, e) => numberWordCountButtonsForSongs[index].BackgroundImage = normalImage; - // 依序建立 0-9 按鈕 - for (int i = 0; i < numberButtonsWordCount.Length; i++) + // 設置點擊事件處理方法 + numberWordCountButtonsForSongs[index].Click += NumberWordCountButton_Click; + + // 設置按鈕的 Tag 屬性為對應的語音符號 + numberWordCountButtonsForSongs[index].Tag = numberWordCountSymbols[index]; + + // 將按鈕添加到表單的控制項集合中 + this.Controls.Add(numberWordCountButtonsForSongs[index]); + } + catch (Exception ex) + { + // 捕捉錯誤並輸出錯誤訊息 + Console.WriteLine($"Error creating button at index {index}: {ex.Message}"); + } + } + + + /// + /// 初始化所有與注音歌手相關的按鈕,包括語音符號按鈕、特殊按鈕及輸入框。 + /// + private void InitializeButtonsForWordCountSongs() + { + // 從配置檔案加載注音符號並初始化按鈕 + LoadNumberWordCountSymbolsFromConfig(); + + // 初始化所有語音按鈕 + InitializeNumberWordCountButtons(); + + // 初始化注音歌手的特殊按鈕(例如音量、搜尋等) + InitializeSpecialButtonsForWordCountSongs(); + + // 初始化注音歌手的輸入框 + InitializeInputBoxWordCountSongs(); + } + + + /// + /// 移除圖像周圍的白色邊框,將邊框的像素透明化。 + /// + /// 待處理的圖像文件路徑。 + /// 處理後的圖像,其中白色邊框已被去除並替換為透明。 + private Image RemoveWhiteBorderForWordCountSongs(string imagePath) + { + // 創建一個 Bitmap 物件來加載圖像 + Bitmap bmp = new Bitmap(imagePath); + + // 定義圖像的矩形區域,這是我們將要操作的區域 + Rectangle rect = new Rectangle(0, 0, bmp.Width, bmp.Height); + + // 鎖定圖像的位圖數據,以便進行直接修改 + BitmapData bmpData = bmp.LockBits(rect, ImageLockMode.ReadWrite, bmp.PixelFormat); + + IntPtr ptr = bmpData.Scan0; // 獲取位圖數據的起始位置 + int bytes = Math.Abs(bmpData.Stride) * bmp.Height; // 計算圖像的總字節數 + byte[] rgbValues = new byte[bytes]; // 用來存儲圖像的像素數據 + System.Runtime.InteropServices.Marshal.Copy(ptr, rgbValues, 0, bytes); // 從圖像數據中複製像素數據到 rgbValues 陣列 + + // 遍歷每個像素點,檢查是否為白色邊框 + for (int y = 0; y < bmp.Height; y++) + { + for (int x = 0; x < bmp.Width; x++) { - numberButtonsWordCount[i] = new Button(); + int position = (y * bmpData.Stride) + (x * 4); // 計算當前像素的位址 + byte b = rgbValues[position]; // 藍色分量 + byte g = rgbValues[position + 1]; // 綠色分量 + byte r = rgbValues[position + 2]; // 紅色分量 + byte a = rgbValues[position + 3]; // alpha 分量(透明度) - // 設定按鈕屬性 (位置、大小、圖片) - ConfigureButton( - numberButtonsWordCount[i], - coords[i, 0], - coords[i, 1], - coords[i, 2] - coords[i, 0], // 計算按鈕寬度 - coords[i, 3] - coords[i, 1], // 計算按鈕高度 - resizedNormalStateImageFor6_1, - resizedMouseOverImageFor6_1, - resizedMouseDownImageFor6_1, - null - ); - - // 調整按鈕位置,使其適應不同解析度 - int newXForWordCount = (int)(((numberButtonsWordCount[i].Location.X / widthRatio) + offsetXWordCount) * widthRatio); - int newYForWordCount = (int)(((numberButtonsWordCount[i].Location.Y / heightRatio) + offsetYWordCount) * heightRatio); - numberButtonsWordCount[i].Location = new Point(newXForWordCount, newYForWordCount); - - // 設定按鈕名稱 - numberButtonsWordCount[i].Name = "NumberButtonWordCount" + i; - numberButtonsWordCount[i].Tag = (i + 1).ToString(); - - // 處理按鈕 0 的特殊名稱與標籤 - if (i == 9) + // 如果當前像素在圖像邊緣且為白色 (255, 255, 255),則將其設為透明 + if ((x < 5 || x > bmp.Width - 5 || y < 5 || y > bmp.Height - 5) && r == 255 && g == 255 && b == 255) { - numberButtonsWordCount[i].Name = "NumberButtonWordCount0"; - numberButtonsWordCount[i].Tag = "0"; + // 將白色像素的 RGB 設置為 255, 255, 255 且 alpha 設為 0 (透明) + rgbValues[position] = 255; + rgbValues[position + 1] = 255; + rgbValues[position + 2] = 255; + rgbValues[position + 3] = 0; // 透明 } - - // 設定點擊事件 - numberButtonsWordCount[i].Click += WordCountButton_Click; - - // 將按鈕加入視窗控制項 - this.Controls.Add(numberButtonsWordCount[i]); } + } - // 建立「修改」按鈕 (Modify) - modifyButtonWordCount = new Button { - Name = "ModifyButtonWordCount", - Tag = "Modify", - Visible = false - }; - ConfigureButton(modifyButtonWordCount, 978, 292, 1081 - 978, 397 - 292, - resizedNormalStateImageFor6_1, resizedMouseOverImageFor6_1, resizedMouseDownImageFor6_1, - ModifyButtonWordCount_Click); + // 將修改後的像素數據重新複製回位圖數據 + System.Runtime.InteropServices.Marshal.Copy(rgbValues, 0, ptr, bytes); + + // 解鎖圖像數據 + bmp.UnlockBits(bmpData); - // 調整「修改」按鈕的位置 - int newX = (int)(((modifyButtonWordCount.Location.X / widthRatio) + offsetXWordCount) * widthRatio); - int newY = (int)(((modifyButtonWordCount.Location.Y / heightRatio) + offsetYWordCount) * heightRatio); - modifyButtonWordCount.Location = new Point(newX, newY); + // 返回處理後的圖像 + return bmp; + } - // 加入「修改」按鈕至視窗 - this.Controls.Add(modifyButtonWordCount); - // 建立「關閉」按鈕 (Close) - closeButtonWordCount = new Button { - Name = "CloseButtonWordCount", - Tag = "Close", - Visible = false - }; - ConfigureButton(closeButtonWordCount, 982, 147, 1082 - 982, 250 - 147, - resizedNormalStateImageFor6_1, resizedMouseOverImageFor6_1, resizedMouseDownImageFor6_1, - CloseButtonWordCount_Click); + /// + /// 初始化與注音歌手相關的特殊按鈕,包括修改、清除和關閉按鈕。 + /// + private void InitializeSpecialButtonsForWordCountSongs() + { + // 初始化修改按鈕 + InitializeModifyButtonWordCountSongs(); - // 調整「關閉」按鈕的位置 - newX = (int)(((closeButtonWordCount.Location.X / widthRatio) + offsetXWordCount) * widthRatio); - newY = (int)(((closeButtonWordCount.Location.Y / heightRatio) + offsetYWordCount) * heightRatio); - closeButtonWordCount.Location = new Point(newX, newY); + // 初始化清除按鈕 + InitializeClearButtonWordCountSongs(); - // 加入「關閉」按鈕至視窗 - this.Controls.Add(closeButtonWordCount); + // 初始化關閉按鈕 + InitializeCloseButtonWordCountSongs(); + } - // 建立輸入框 (RichTextBox) 供使用者輸入詞數 - inputBoxWordCount = new RichTextBox(); - inputBoxWordCount.Name = "inputBoxWordCount"; - // 設定輸入框位置與大小 - ResizeAndPositionControl(inputBoxWordCount, 645 + offsetXWordCount, 197 + offsetYWordCount, 986 - 645, 281 - 197); - inputBoxWordCount.ForeColor = Color.Black; - inputBoxWordCount.Font = new Font("細明體", (float)26 / 900 * Screen.PrimaryScreen.Bounds.Height, FontStyle.Regular); + /// + /// 初始化「修改」按鈕,設定按鈕的坐標、圖片和點擊事件。 + /// + private void InitializeModifyButtonWordCountSongs() + { + // 加載配置數據 + var data = LoadConfigDataforWordCountSongs(); - // 設定輸入框內容變更時的處理邏輯 - inputBoxWordCount.TextChanged += (sender, e) => + // 讀取按鈕坐標 + modifyButtonWordCountCoords = LoadSpecialButtonCoordinatesForWordCountSongs(data, "SpecialButtonCoordinates", "modifyButtonWordCountSongs"); + + // 加載按鈕圖片(正常、鼠標懸停、鼠標按下) + var buttonImages = LoadButtonImagesForWordCountSongs(data, "ModifyButtonImagesWordCount"); + + // 創建「修改」按鈕,並設置坐標、圖片及點擊事件 + modifyButtonWordCountSongs = CreateSpecialButtonForWordCountSongs( + "btnModifyWordCountSongs", // 按鈕名稱 + modifyButtonWordCountCoords, // 按鈕坐標 + buttonImages.normal, // 正常狀態圖片 + buttonImages.mouseOver, // 鼠標懸停圖片 + buttonImages.mouseDown, // 鼠標按下圖片 + ModifyButtonWordCountSongs_Click // 按鈕點擊事件 + ); + } + + /// + /// 處理「修改」按鈕的點擊事件,該事件會刪除輸入框中的最後一個字符。 + /// + /// 觸發事件的對象 + /// 事件參數 + private void ModifyButtonWordCountSongs_Click(object sender, EventArgs e) + { + // 如果輸入框不為空,且包含輸入內容,則刪除最後一個字符 + if (this.Controls.Contains(inputBoxWordCountSongs) && inputBoxWordCountSongs.Text.Length > 0) + { + inputBoxWordCountSongs.Text = inputBoxWordCountSongs.Text.Substring(0, inputBoxWordCountSongs.Text.Length - 1); + } + } + + + /// + /// 初始化「清除」按鈕,設定按鈕的坐標、圖片和點擊事件。 + /// + private void InitializeClearButtonWordCountSongs() + { + // 加載配置數據 + var data = LoadConfigDataforWordCountSongs(); + + // 讀取按鈕坐標 + clearButtonWordCountCoords = LoadSpecialButtonCoordinatesForWordCountSongs(data, "SpecialButtonCoordinates", "clearButtonWordCountSongs"); + + // 加載按鈕圖片(正常、鼠標懸停、鼠標按下) + var buttonImages = LoadButtonImagesForWordCountSongs(data, "ClearButtonImagesWordCount"); + + // 創建「清除」按鈕,並設置坐標、圖片及點擊事件 + clearButtonWordCountSongs = CreateSpecialButtonForWordCountSongs( + "btnClearWordCountSongs", // 按鈕名稱 + clearButtonWordCountCoords, // 按鈕坐標 + buttonImages.normal, // 正常狀態圖片 + buttonImages.mouseOver, // 鼠標懸停圖片 + buttonImages.mouseDown, // 鼠標按下圖片 + ClearButtonWordCountSongs_Click // 按鈕點擊事件 + ); + } + + /// + /// 處理「清除」按鈕的點擊事件,該事件會清空輸入框中的所有文本。 + /// + /// 觸發事件的對象 + /// 事件參數 + private void ClearButtonWordCountSongs_Click(object sender, EventArgs e) + { + // 如果輸入框不為空,則清空該框的文本內容 + if (this.Controls.Contains(inputBoxWordCountSongs) && inputBoxWordCountSongs.Text.Length > 0) + { + inputBoxWordCountSongs.Text = ""; + } + } + + + /// + /// 初始化「關閉」按鈕,設定按鈕的坐標、圖片和點擊事件。 + /// + private void InitializeCloseButtonWordCountSongs() + { + // 加載配置數據 + var data = LoadConfigDataforWordCountSongs(); + + // 讀取按鈕坐標 + closeButtonWordCountCoords = LoadSpecialButtonCoordinatesForWordCountSongs(data, "SpecialButtonCoordinates", "closeButtonWordCountSongs"); + + // 加載按鈕圖片(正常、鼠標懸停、鼠標按下) + var buttonImages = LoadButtonImagesForWordCountSongs(data, "CloseButtonImagesWordCount"); + + // 創建「關閉」按鈕,並設置坐標、圖片及點擊事件 + closeButtonWordCountSongs = CreateSpecialButtonForWordCountSongs( + "btnCloseWordCountSongs", // 按鈕名稱 + closeButtonWordCountCoords, // 按鈕坐標 + buttonImages.normal, // 正常狀態圖片 + buttonImages.mouseOver, // 鼠標懸停圖片 + buttonImages.mouseDown, // 鼠標按下圖片 + CloseButtonWordCountSongs_Click // 按鈕點擊事件 + ); + } + + + /// + /// 「關閉」按鈕的點擊事件處理方法。 + /// 隱藏 WordCount 歌手圖片框以及與其相關的按鈕。 + /// + /// 觸發事件的對象,這裡是關閉按鈕。 + /// 事件參數。 + private void CloseButtonWordCountSongs_Click(object sender, EventArgs e) + { + // 隱藏 WordCount 歌手圖片框 + pictureBoxWordCountSongs.Visible = false; + + // 隱藏與 WordCount 歌手相關的所有按鈕 + SetWordCountSongsAndButtonsVisibility(false); + } + + + /// + /// 創建一個特殊的按鈕,並設定其顯示屬性、事件處理和位置。 + /// + /// 按鈕的名稱。 + /// 按鈕的坐標和大小,包含 X, Y, 寬度和高度。 + /// 按鈕正常狀態下的背景圖片路徑。 + /// 鼠標懸停時按鈕的背景圖片路徑。 + /// 鼠標點擊時按鈕的背景圖片路徑。 + /// 按鈕的點擊事件處理程序。 + /// 創建並返回的按鈕對象。 + private Button CreateSpecialButtonForWordCountSongs(string name, (int X, int Y, int Width, int Height) coords, string normalImagePath, string mouseOverImagePath, string mouseDownImagePath, EventHandler clickEventHandler) + { + // 創建按鈕並設定基本屬性 + var button = new Button + { + Name = name, + FlatStyle = FlatStyle.Flat, + FlatAppearance = { BorderSize = 0, MouseDownBackColor = Color.Transparent, MouseOverBackColor = Color.Transparent }, + BackgroundImageLayout = ImageLayout.Stretch, + BackgroundImage = Image.FromFile(Path.Combine(Application.StartupPath, normalImagePath)) + }; + + // 設定按鈕的大小和位置 + ResizeAndPositionButton(button, coords.X, coords.Y, coords.Width, coords.Height); + + // 設定鼠標事件:進入、離開、按下、放開 + button.MouseEnter += (sender, e) => button.BackgroundImage = Image.FromFile(Path.Combine(Application.StartupPath, mouseOverImagePath)); + button.MouseLeave += (sender, e) => button.BackgroundImage = Image.FromFile(Path.Combine(Application.StartupPath, normalImagePath)); + button.MouseDown += (sender, e) => button.BackgroundImage = Image.FromFile(Path.Combine(Application.StartupPath, mouseDownImagePath)); + button.MouseUp += (sender, e) => button.BackgroundImage = Image.FromFile(Path.Combine(Application.StartupPath, normalImagePath)); + + // 註冊點擊事件處理 + button.Click += clickEventHandler; + + // 將按鈕添加到控件集合中 + this.Controls.Add(button); + + return button; + } + + + /// + /// 初始化 WordCount 歌手的輸入框,並設定其屬性與事件處理程序。 + /// + private void InitializeInputBoxWordCountSongs() + { + try + { + // 加載輸入框配置 + LoadInputBoxConfigForWordCountSongs(); + + // 創建一個 RichTextBox 控件來作為輸入框 + inputBoxWordCountSongs = new RichTextBox { - string searchText = inputBoxWordCount.Text; - int targetLength = 0; + Name = "inputBoxWordCountSongs", + ForeColor = inputBoxWordCountForeColor, // 設定文字顏色 + Font = new Font(inputBoxWordCountFontName, inputBoxWordCountFontSize, inputBoxWordCountFontStyle), // 設定字體樣式 + ScrollBars = RichTextBoxScrollBars.None // 不顯示滾動條 + }; - // 檢查輸入的是否為數字 - if (int.TryParse(searchText, out targetLength)) + // 調整和定位輸入框的位置及大小 + ResizeAndPositionControl(inputBoxWordCountSongs, inputBoxWordCountCoords.X, inputBoxWordCountCoords.Y, inputBoxWordCountCoords.Width, inputBoxWordCountCoords.Height); + + // 設定文本變更事件,當輸入框內容改變時觸發 + inputBoxWordCountSongs.TextChanged += (sender, e) => + { + string searchText = inputBoxWordCountSongs.Text; // 取得輸入內容 + if (int.TryParse(searchText, out int length)) { - // 根據詞數長度篩選歌曲 - var searchResults = allSongs.Where(song => song.Song.Replace(" ", "").Length == targetLength).ToList(); + // 顯示搜尋結果 + var searchResults = allSongs + .Where(song => song.Song.Length == length) + .ToList(); + + // 重置分頁 currentPage = 0; currentSongList = searchResults; totalPages = (int)Math.Ceiling((double)searchResults.Count / itemsPerPage); - // 更新多頁面面板 + // 更新多頁面面板的內容 multiPagePanel.currentPageIndex = 0; multiPagePanel.LoadSongs(currentSongList); } + + + }; + // 將輸入框加入到窗體的控件集合中 + this.Controls.Add(inputBoxWordCountSongs); + } + catch (Exception ex) + { + // 如果初始化過程中出現錯誤,則在控制台輸出錯誤信息 + Console.WriteLine("Error initializing inputBoxWordCountSongs: " + ex.Message); + } + } + + + /// + /// 從配置文件 `config.ini` 中加載輸入框的設置,包括位置、大小、字體等屬性。 + /// + private void LoadInputBoxConfigForWordCountSongs() + { + try + { + // 創建 INI 解析器 + var parser = new FileIniDataParser(); + string iniFilePath = "config.ini"; // 配置文件的路徑 + + IniData data; + // 打開並讀取配置文件 + using (var reader = new StreamReader(iniFilePath, Encoding.UTF8)) + { + data = parser.ReadData(reader); + } + + // 從配置中加載輸入框的坐標和大小 + inputBoxWordCountCoords = ( + int.Parse(data["InputBoxWordCountSongs"]["X"]), // 輸入框的 X 坐標 + int.Parse(data["InputBoxWordCountSongs"]["Y"]), // 輸入框的 Y 坐標 + int.Parse(data["InputBoxWordCountSongs"]["Width"]), // 輸入框的寬度 + int.Parse(data["InputBoxWordCountSongs"]["Height"]) // 輸入框的高度 + ); + + // 從配置中加載字體屬性 + inputBoxWordCountFontName = data["InputBoxWordCountSongs"]["FontName"]; // 字體名稱 + inputBoxWordCountFontSize = float.Parse(data["InputBoxWordCountSongs"]["FontSize"]); // 字體大小 + inputBoxWordCountFontStyle = (FontStyle)Enum.Parse(typeof(FontStyle), data["InputBoxWordCountSongs"]["FontStyle"]); // 字體樣式 + inputBoxWordCountForeColor = Color.FromName(data["InputBoxWordCountSongs"]["ForeColor"]); // 字體顏色 + + } + catch (Exception ex) + { + // 若發生錯誤,顯示錯誤信息 + Console.WriteLine("Error loading inputBox configuration: " + ex.Message); + } + } + + + /// + /// 存儲 `pictureBoxWordCountSongs` 控制項的坐標和大小設置。 + /// + /// + /// 這個元組包含了 `X`、`Y` 坐標以及 `Width`、`Height` 大小,用於配置 `pictureBoxWordCountSongs` 的位置和大小。 + /// + private (int X, int Y, int Width, int Height) pictureBoxWordCountSongCoords; + + /// + /// 從配置檔案中讀取 `PictureBoxWordCountSongs` 控制項的坐標和大小設置。 + /// + private void LoadPictureBoxWordCountSongCoordsFromConfig() + { + var parser = new FileIniDataParser(); + IniData data = parser.ReadFile("config.ini"); + + var coords = data["PictureBoxWordCountSongs"]; + pictureBoxWordCountSongCoords = ( + int.Parse(coords["X"]), + int.Parse(coords["Y"]), + int.Parse(coords["Width"]), + int.Parse(coords["Height"]) + ); + } + + + /// + /// 顯示圖片並根據配置文件設置顯示區域的大小和位置。 + /// + /// 圖片的路徑。 + private void ShowImageOnPictureBoxWordCountSongs(string imagePath) + { + // 讀取配置文件中的顯示區域設置 + LoadPictureBoxWordCountSongCoordsFromConfig(); + + // 加載原始圖片 + Bitmap originalImage = new Bitmap(imagePath); + + // 創建顯示區域,根據配置文件中的坐標和大小設置 + Rectangle displayArea = new Rectangle(pictureBoxWordCountSongCoords.X, pictureBoxWordCountSongCoords.Y, pictureBoxWordCountSongCoords.Width, pictureBoxWordCountSongCoords.Height); + + // 設置圖片到 PictureBox + pictureBoxWordCountSongs.Image = originalImage; + + // 調整 PictureBox 大小和位置 + ResizeAndPositionPictureBox(pictureBoxWordCountSongs, displayArea.X, displayArea.Y, displayArea.Width, displayArea.Height); + + // 顯示圖片 + pictureBoxWordCountSongs.Visible = true; + } + + + /// + /// 設置注音歌手相關控制項(包括圖片框、按鈕和輸入框)的顯示或隱藏狀態。 + /// + /// 指定控件是否可見。True 為顯示,False 為隱藏。 + private void SetWordCountSongsAndButtonsVisibility(bool isVisible) + { + // 定義一個動作來處理控制項的顯示或隱藏 + System.Action action = () => + { + try + { + // 暫停控制項佈局的重新排版,提高效率 + SuspendLayout(); + + // 檢查並設置圖片框的可見性 + if (pictureBoxWordCountSongs == null) + { + Console.WriteLine("pictureBoxWordCountSongs is null"); + } else { - // 若輸入非數字,則清空當前歌曲列表 - currentSongList.Clear(); + pictureBoxWordCountSongs.Visible = isVisible; + if (isVisible) pictureBoxWordCountSongs.BringToFront(); // 如果顯示,將其置於最前 } - }; - // 加入輸入框至視窗 - this.Controls.Add(inputBoxWordCount); - } + // 檢查並設置拼音按鈕的可見性 + if (numberWordCountButtonsForSongs == null) + { + Console.WriteLine("numberWordCountButtonsForSongs is null"); + } + else + { + foreach (var button in numberWordCountButtonsForSongs) + { + if (button == null) + { + Console.WriteLine("One of the numberWordCountButtonsForSongs is null"); + } + else + { + button.Visible = isVisible; + if (isVisible) button.BringToFront(); // 如果顯示,將其置於最前 + } + } + } + // 檢查並設置修改按鈕的可見性 + if (modifyButtonWordCountSongs == null) + { + Console.WriteLine("modifyButtonWordCountSongs is null"); + } + else + { + modifyButtonWordCountSongs.Visible = isVisible; + if (isVisible) modifyButtonWordCountSongs.BringToFront(); // 如果顯示,將其置於最前 + } - - /// - /// 處理數字按鈕的點擊事件,將按鈕對應的數字 (Tag) 加入輸入框 inputBoxWordCount 中。 - /// - /// 觸發事件的按鈕 - /// 事件參數 - private void WordCountButton_Click(object sender, EventArgs e) - { - // 嘗試將 sender 轉換為 Button 類型 - var button = sender as Button; + // 檢查並設置清除按鈕的可見性 + if (clearButtonWordCountSongs == null) + { + Console.WriteLine("clearButtonWordCountSongs is null"); + } + else + { + clearButtonWordCountSongs.Visible = isVisible; + if (isVisible) clearButtonWordCountSongs.BringToFront(); // 如果顯示,將其置於最前 + } - // 確保按鈕不為空,且擁有有效的 Tag 值 - if (button != null && button.Tag != null) + // 檢查並設置關閉按鈕的可見性 + if (closeButtonWordCountSongs == null) + { + Console.WriteLine("closeButtonWordCountSongs is null"); + } + else + { + closeButtonWordCountSongs.Visible = isVisible; + if (isVisible) closeButtonWordCountSongs.BringToFront(); // 如果顯示,將其置於最前 + } + + // 檢查並設置輸入框的可見性 + if (inputBoxWordCountSongs == null) + { + Console.WriteLine("inputBoxWordCountSongs is null"); + } + else + { + inputBoxWordCountSongs.Visible = isVisible; + if (isVisible) inputBoxWordCountSongs.BringToFront(); // 如果顯示,將其置於最前 + } + + // 恢復控制項的佈局重新排版 + ResumeLayout(); + PerformLayout(); + + // 刷新所有控制項的顯示 + pictureBoxWordCountSongs?.Refresh(); + if (numberWordCountButtonsForSongs != null) + { + foreach (var button in numberWordCountButtonsForSongs) + { + button?.Refresh(); // 刷新每個按鈕 + } + } + modifyButtonWordCountSongs?.Refresh(); + clearButtonWordCountSongs?.Refresh(); + closeButtonWordCountSongs?.Refresh(); + inputBoxWordCountSongs?.Refresh(); + } + catch (Exception ex) { - // 將按鈕的 Tag 值 (數字) 追加到輸入框中 - inputBoxWordCount.Text += button.Tag.ToString(); + Console.WriteLine("Error in SetWordCountSongsAndButtonsVisibility: " + ex.Message); + } + }; + + // 檢查是否需要在主執行緒外執行 + if (this.InvokeRequired) + { + this.Invoke(action); // 如果需要,透過主執行緒執行 + } + else + { + action(); // 否則直接執行 + } + } + private void NumberWordCountButton_Click(object sender, EventArgs e) + { + var button = sender as Button; + if (button != null && button.Tag != null) + { + + if (inputBoxWordCountSongs.Visible) + { + inputBoxWordCountSongs.Text += button.Tag.ToString(); } } + } - /// - /// 關閉詞數輸入界面,隱藏相關的 PictureBox 和按鈕。 - /// - /// 觸發事件的按鈕。 - /// 事件參數。 - private void CloseButtonWordCount_Click(object sender, EventArgs e) - { - // 設定詞數輸入界面及其按鈕的可見性為 false,使其隱藏 - SetPictureBoxWordCountAndButtonsVisibility(false); - } } } \ No newline at end of file diff --git a/PrimaryFormParts/SongSearch/PrimaryForm.SongSearch.cs b/PrimaryFormParts/SongSearch/PrimaryForm.SongSearch.cs index 0f3daaa..6f442f1 100644 --- a/PrimaryFormParts/SongSearch/PrimaryForm.SongSearch.cs +++ b/PrimaryFormParts/SongSearch/PrimaryForm.SongSearch.cs @@ -131,7 +131,7 @@ namespace DualScreenDemo // 初始化「筆劃搜尋」按鈕 InitializeSearchButton(ref wordCountSearchSongButton, "wordCountSearchSongButton", 1214, 418, 209, 59, ref wordCountSearchSongNormalBackground, ref wordCountSearchSongActiveBackground, - normalStateImageSongQuery, mouseDownImageSongQuery, WordCountSearchSong_Click); + normalStateImageSongQuery, mouseDownImageSongQuery, WordCountSearchSongsButton_Click); // 初始化「手寫搜尋」按鈕 InitializeSearchButton(ref handWritingSearchSongButton, "handWritingSearchSongButton", @@ -141,7 +141,7 @@ namespace DualScreenDemo // 初始化「數字搜尋」按鈕 InitializeSearchButton(ref numberSearchSongButton, "numberSearchSongButton", 1214, 544, 209, 58, ref numberSearchSongNormalBackground, ref numberSearchSongActiveBackground, - normalStateImageSongQuery, mouseDownImageSongQuery, NumberSearchButton2_Click); + normalStateImageSongQuery, mouseDownImageSongQuery, SongIDSearchSongsButton_Click); } } } diff --git a/bin/config.ini b/bin/config.ini index 5e09827..9400e17 100644 --- a/bin/config.ini +++ b/bin/config.ini @@ -7,8 +7,8 @@ ZhuYinSongs = themes\superstar\歌名\注音\VOD_歌名查詢_注音查詢(按 EnglishSongs = themes\superstar\歌名\英文\VOD_歌名查詢_英文查詢(按鍵)_歌星查詢-注音查詢_未按.png PinYinSongs = themes\superstar\歌星\拼音\VOD_歌星查詢_拼音查詢(按鍵)_歌星查詢-注音查詢_未按.png HandWritingSongs = themes\superstar\歌星\手寫\3.歌星查詢(手寫按鍵)_未按.png -WordCountSongs = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)_未按.png -SongIDSearch = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)_未按.png +WordCountSongs = themes\superstar\歌名\字數\VOD_歌名查詢_編號查詢(按鍵)_未按_沒有確認.png +SongIDSearch = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)_未按_沒有確認.png [PictureBoxZhuYinSingers] X = 130 @@ -46,12 +46,6 @@ Y = 350 Width = 1079 Height = 394 -[PictureBoxWordCountSongs] -X = 130 -Y = 350 -Width = 1079 -Height = 394 - [PhoneticSymbols] Symbols=ㄅ,ㄉ,ㄍ,ㄐ,ㄓ,ㄗ,ㄛ,ㄡ,ㄤ,ㄧ,ㄆ,ㄊ,ㄎ,ㄑ,ㄔ,ㄘ,ㄜ,ㄢ,ㄦ,ㄨ,ㄇ,ㄋ,ㄏ,ㄒ,ㄕ,ㄙ,ㄞ,ㄣ,ㄩ,ㄈ,ㄌ, ,ㄖ,ㄚ,ㄠ @@ -117,6 +111,13 @@ closeButtonPinYinSongs = 1091,642,94,87 refillButtonHandWritingSongs = 918,372,70,65 clearButtonHandWritingSongs = 996,372,70,65 closeButtonForSongs = 1074,372,70,65 +modifyButtonWordCountSongs = 926,624,72,67 +clearButtonWordCountSongs = 845,624,72,67 +closeButtonWordCountSongs = 1088,624,72,67 +modifyButtonSongIDSearch = 811,643,94,87 +clearButtonSongIDSearch = 692,643,93,87 +closeButtonSongIDSearch = 1051,643,94,87 + [ModifyButtonImagesZhuYin] normal = themes\superstar\歌星\注音\VOD_歌星查詢_注音查詢(按鍵)-38.png @@ -605,31 +606,118 @@ FontSize = 26 FontStyle = Regular ForeColor = Black +[PictureBoxWordCountSongs] +X = 790 +Y = 350 +Width = 420 +Height = 350 + [InputBoxWordCountSongs] -X=150 -Y=264 -Width=596 -Height=63 -FontName=微軟正黑體 -FontSize=26 -FontStyle=Bold -ForeColor=Black +X = 800 +Y = 405 +Width = 400 +Height = 60 +FontName = Times New Roman +FontSize = 26 +FontStyle = Regular +ForeColor = Black +[NumberWordCountSymbols] +Symbols=1,2,3,4,5,6,7,8,9,0 -[NumberButtonCoordinatesWithWordCount] -button1 = 157,201,27,32 -button2 = 187,201,27,32 -button3 = 217,201,27,32 -button4 = 247,201,27,32 -button5 = 277,200,27,32 -button6 = 307,201,27,32 -button7 = 337,201,27,32 -button8 = 367,201,27,32 -button9 = 397,201,27,32 -button10 = 427,201,27,32 +[NumberWordCountButtonCoordinates] +button0 = 650,420,70,65 +button1 = 804,474,72,67 +button2 = 886,474,72,67 +button3 = 965,474,73,67 +button4 = 1048,474,72,67 +button5 = 1129,474,72,67 +button6 = 804,548,72,67 +button7 = 886,548,72,67 +button8 = 965,548,73,67 +button9 = 1048,548,72,67 +button10 = 1129,548,72,67 +[NumberWordCountButtonImages] +button0_normal = themes\superstar\歌名\字數\VOD_歌名查詢_編號查詢(按鍵)-02.png +button0_mouseDown = themes\superstar\歌名\字數\VOD_歌名查詢_編號查詢(按鍵)-17.png +button0_mouseOver = themes\superstar\歌名\字數\VOD_歌名查詢_編號查詢(按鍵)-02.png +button1_normal = themes\superstar\歌名\字數\VOD_歌名查詢_編號查詢(按鍵)-03.png +button1_mouseDown = themes\superstar\歌名\字數\VOD_歌名查詢_編號查詢(按鍵)-18.png +button1_mouseOver = themes\superstar\歌名\字數\VOD_歌名查詢_編號查詢(按鍵)-03.png +button2_normal = themes\superstar\歌名\字數\VOD_歌名查詢_編號查詢(按鍵)-04.png +button2_mouseDown = themes\superstar\歌名\字數\VOD_歌名查詢_編號查詢(按鍵)-19.png +button2_mouseOver = themes\superstar\歌名\字數\VOD_歌名查詢_編號查詢(按鍵)-04.png +button3_normal = themes\superstar\歌名\字數\VOD_歌名查詢_編號查詢(按鍵)-05.png +button3_mouseDown = themes\superstar\歌名\字數\VOD_歌名查詢_編號查詢(按鍵)-20.png +button3_mouseOver = themes\superstar\歌名\字數\VOD_歌名查詢_編號查詢(按鍵)-05.png +button4_normal = themes\superstar\歌名\字數\VOD_歌名查詢_編號查詢(按鍵)-06.png +button4_mouseDown = themes\superstar\歌名\字數\VOD_歌名查詢_編號查詢(按鍵)-21.png +button4_mouseOver = themes\superstar\歌名\字數\VOD_歌名查詢_編號查詢(按鍵)-06.png +button5_normal = themes\superstar\歌名\字數\VOD_歌名查詢_編號查詢(按鍵)-07.png +button5_mouseDown = themes\superstar\歌名\字數\VOD_歌名查詢_編號查詢(按鍵)-22.png +button5_mouseOver = themes\superstar\歌名\字數\VOD_歌名查詢_編號查詢(按鍵)-07.png +button6_normal = themes\superstar\歌名\字數\VOD_歌名查詢_編號查詢(按鍵)-08.png +button6_mouseDown = themes\superstar\歌名\字數\VOD_歌名查詢_編號查詢(按鍵)-23.png +button6_mouseOver = themes\superstar\歌名\字數\VOD_歌名查詢_編號查詢(按鍵)-08.png +button7_normal = themes\superstar\歌名\字數\VOD_歌名查詢_編號查詢(按鍵)-09.png +button7_mouseDown = themes\superstar\歌名\字數\VOD_歌名查詢_編號查詢(按鍵)-24.png +button7_mouseOver = themes\superstar\歌名\字數\VOD_歌名查詢_編號查詢(按鍵)-09.png +button8_normal = themes\superstar\歌名\字數\VOD_歌名查詢_編號查詢(按鍵)-10.png +button8_mouseDown = themes\superstar\歌名\字數\VOD_歌名查詢_編號查詢(按鍵)-25.png +button8_mouseOver = themes\superstar\歌名\字數\VOD_歌名查詢_編號查詢(按鍵)-10.png +button9_normal = themes\superstar\歌名\字數\VOD_歌名查詢_編號查詢(按鍵)-11.png +button9_mouseDown = themes\superstar\歌名\字數\VOD_歌名查詢_編號查詢(按鍵)-26.png +button9_mouseOver = themes\superstar\歌名\字數\VOD_歌名查詢_編號查詢(按鍵)-11.png -[NumberButtonImagesWithWordCount] +[ModifyButtonImagesWordCount] +normal = themes\superstar\歌名\字數\VOD_歌名查詢_編號查詢(按鍵)-13.png +mouseOver = themes\superstar\歌名\字數\VOD_歌名查詢_編號查詢(按鍵)-13.png +mouseDown = themes\superstar\歌名\字數\VOD_歌名查詢_編號查詢(按鍵)-28.png + +[ClearButtonImagesWordCount] +normal = themes\superstar\歌名\字數\VOD_歌名查詢_編號查詢(按鍵)-14.png +mouseOver = themes\superstar\歌名\字數\VOD_歌名查詢_編號查詢(按鍵)-14.png +mouseDown = themes\superstar\歌名\字數\VOD_歌名查詢_編號查詢(按鍵)-29.png + +[CloseButtonImagesWordCount] +normal = themes\superstar\歌名\字數\VOD_歌名查詢_編號查詢(按鍵)-15.png +mouseOver = themes\superstar\歌名\字數\VOD_歌名查詢_編號查詢(按鍵)-15.png +mouseDown = themes\superstar\歌名\字數\VOD_歌名查詢_編號查詢(按鍵)-30.png + +[PictureBoxSongIDSearch] +X = 650 +Y = 300 +Width = 554 +Height = 442 + +[InputBoxSongIDSearch] +X = 660 +Y = 370 +Width = 530 +Height = 63 +FontName = Times New Roman +FontSize = 26 +FontStyle = Regular +ForeColor = Black + +[NumberSongIDSymbols] +Symbols=1,2,3,4,5,6,7,8,9,0 + +[NumberSongIDButtonCoordinates] +button0 = 650,300,94,87 +button1 = 660,445,94,87 +button2 = 770,445,94,87 +button3 = 880,445,94,87 +button4 = 990,445,94,87 +button5 = 1100,445,94,87 +button6 = 660,545,94,87 +button7 = 770,545,94,87 +button8 = 880,545,94,87 +button9 = 990,545,94,87 +button10 = 1100,545,94,87 + +[NumberSongIDButtonImages] button0_normal = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-02.png button0_mouseDown = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-17.png button0_mouseOver = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-02.png @@ -661,17 +749,17 @@ button9_normal = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢( button9_mouseDown = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-26.png button9_mouseOver = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-11.png -[ModifyButtonImagesWordCount] -normal = themes\superstar\歌星\拼音\VOD_歌名查詢_編號查詢(按鍵)-13.png -mouseOver = themes\superstar\歌星\拼音\VOD_歌名查詢_編號查詢(按鍵)-13.png -mouseDown = themes\superstar\歌星\拼音\VOD_歌名查詢_編號查詢(按鍵)-28.png +[ModifyButtonImagesSongID] +normal = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-13.png +mouseOver = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-13.png +mouseDown = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-28.png -[ClearButtonImagesWordCount] -normal = themes\superstar\歌名\拼音\VOD_歌名查詢_編號查詢(按鍵)-14.png -mouseOver = themes\superstar\歌名\拼音\VOD_歌名查詢_編號查詢(按鍵)-14.png -mouseDown = themes\superstar\歌名\拼音\VOD_歌名查詢_編號查詢(按鍵)-29.png +[ClearButtonImagesSongID] +normal = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-14.png +mouseOver = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-14.png +mouseDown = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-29.png -[CloseButtonImagesWordCount] -normal = themes\superstar\歌名\拼音\VOD_歌名查詢_編號查詢(按鍵)-15.png -mouseOver = themes\superstar\歌名\拼音\VOD_歌名查詢_編號查詢(按鍵)-15.png -mouseDown = themes\superstar\歌名\拼音\VOD_歌名查詢_編號查詢(按鍵)-30.png \ No newline at end of file +[CloseButtonImagesSongID] +normal = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-15.png +mouseOver = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-15.png +mouseDown = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-30.png \ No newline at end of file diff --git a/bin/mainlog.txt b/bin/mainlog.txt index bfda36b..1c20d5d 100644 --- a/bin/mainlog.txt +++ b/bin/mainlog.txt @@ -22,3 +22,84 @@ 注意: 與組件繫結失敗記錄相關的效能會有部分負面影響。 若要關閉此功能,請移除登錄值 [HKLM\Software\Microsoft\Fusion!EnableLog]。 +[2025/3/21 上午 10:00:57] System.NullReferenceException: 並未將物件參考設定為物件的執行個體。 + 於 DualScreenDemo.PrimaryForm.LoadNumberWordCountSymbolsFromConfig() + 於 DualScreenDemo.PrimaryForm.InitializeButtonsForWordCountSongs() + 於 DualScreenDemo.PrimaryForm.InitializeFormAndControls() + 於 DualScreenDemo.PrimaryForm..ctor() + 於 DualScreenDemo.Program.Main() +[2025/3/21 上午 10:09:34] System.NullReferenceException: 並未將物件參考設定為物件的執行個體。 + 於 DualScreenDemo.PrimaryForm.LoadNumberWordCountSymbolsFromConfig() + 於 DualScreenDemo.PrimaryForm.InitializeButtonsForWordCountSongs() + 於 DualScreenDemo.PrimaryForm.InitializeFormAndControls() + 於 DualScreenDemo.PrimaryForm..ctor() + 於 DualScreenDemo.Program.Main() +[2025/3/21 上午 10:10:11] System.NullReferenceException: 並未將物件參考設定為物件的執行個體。 + 於 DualScreenDemo.PrimaryForm.LoadButtonCoordinatesForWordCountSongs(IniData data, String section, Int32 buttonCount) + 於 DualScreenDemo.PrimaryForm.InitializeNumberWordCountButtons() + 於 DualScreenDemo.PrimaryForm.InitializeButtonsForWordCountSongs() + 於 DualScreenDemo.PrimaryForm.InitializeFormAndControls() + 於 DualScreenDemo.PrimaryForm..ctor() + 於 DualScreenDemo.Program.Main() +[2025/3/21 上午 10:16:17] System.IO.FileNotFoundException: C:\jasonchen\superstar\bin\themes\superstar\歌星\拼音\VOD_歌名查詢_編號查詢(按鍵)-13.png + 於 System.Drawing.Image.FromFile(String filename, Boolean useEmbeddedColorManagement) + 於 DualScreenDemo.PrimaryForm.CreateSpecialButtonForWordCountSongs(String name, ValueTuple`4 coords, String normalImagePath, String mouseOverImagePath, String mouseDownImagePath, EventHandler clickEventHandler) + 於 DualScreenDemo.PrimaryForm.InitializeModifyButtonWordCountSongs() + 於 DualScreenDemo.PrimaryForm.InitializeSpecialButtonsForWordCountSongs() + 於 DualScreenDemo.PrimaryForm.InitializeButtonsForWordCountSongs() + 於 DualScreenDemo.PrimaryForm.InitializeFormAndControls() + 於 DualScreenDemo.PrimaryForm..ctor() + 於 DualScreenDemo.Program.Main() +[2025/3/21 上午 10:28:23] System.IO.FileNotFoundException: C:\jasonchen\superstar\bin\themes\superstar\歌星\編號\VOD_歌名查詢_編號查詢(按鍵)-13.png + 於 System.Drawing.Image.FromFile(String filename, Boolean useEmbeddedColorManagement) + 於 DualScreenDemo.PrimaryForm.CreateSpecialButtonForWordCountSongs(String name, ValueTuple`4 coords, String normalImagePath, String mouseOverImagePath, String mouseDownImagePath, EventHandler clickEventHandler) + 於 DualScreenDemo.PrimaryForm.InitializeModifyButtonWordCountSongs() + 於 DualScreenDemo.PrimaryForm.InitializeSpecialButtonsForWordCountSongs() + 於 DualScreenDemo.PrimaryForm.InitializeButtonsForWordCountSongs() + 於 DualScreenDemo.PrimaryForm.InitializeFormAndControls() + 於 DualScreenDemo.PrimaryForm..ctor() + 於 DualScreenDemo.Program.Main() +[2025/3/21 上午 10:54:46] System.NullReferenceException: 並未將物件參考設定為物件的執行個體。 + 於 DualScreenDemo.PrimaryForm.InitializeFormAndControls() + 於 DualScreenDemo.PrimaryForm..ctor() + 於 DualScreenDemo.Program.Main() +[2025/3/21 上午 11:24:16] System.NullReferenceException: 並未將物件參考設定為物件的執行個體。 + 於 DualScreenDemo.PrimaryForm.InitializeFormAndControls() + 於 DualScreenDemo.PrimaryForm..ctor() + 於 DualScreenDemo.Program.Main() +[2025/3/21 上午 11:24:29] System.NullReferenceException: 並未將物件參考設定為物件的執行個體。 + 於 DualScreenDemo.PrimaryForm.InitializeFormAndControls() + 於 DualScreenDemo.PrimaryForm..ctor() + 於 DualScreenDemo.Program.Main() +[2025/3/21 上午 11:24:36] System.NullReferenceException: 並未將物件參考設定為物件的執行個體。 + 於 DualScreenDemo.PrimaryForm.InitializeFormAndControls() + 於 DualScreenDemo.PrimaryForm..ctor() + 於 DualScreenDemo.Program.Main() +[2025/3/21 上午 11:24:43] System.NullReferenceException: 並未將物件參考設定為物件的執行個體。 + 於 DualScreenDemo.PrimaryForm.InitializeFormAndControls() + 於 DualScreenDemo.PrimaryForm..ctor() + 於 DualScreenDemo.Program.Main() +[2025/3/21 下午 03:16:32] System.NullReferenceException: 並未將物件參考設定為物件的執行個體。 + 於 DualScreenDemo.PrimaryForm.LoadNumberWordCountSymbolsFromConfig() + 於 DualScreenDemo.PrimaryForm.InitializeButtonsForWordCountSongs() + 於 DualScreenDemo.PrimaryForm.InitializeFormAndControls() + 於 DualScreenDemo.PrimaryForm..ctor() + 於 DualScreenDemo.Program.Main() +[2025/3/24 上午 10:25:46] IniParser.Exceptions.ParsingException: Duplicate section with name 'PictureBoxWordCountSongs' on line '[PictureBoxWordCountSongs]' while parsing line number 0 with value '' - IniParser version: 2.5.2.0 while parsing line number 684 with value '[PictureBoxWordCountSongs]' - IniParser version: 2.5.2.0 ---> IniParser.Exceptions.ParsingException: Duplicate section with name 'PictureBoxWordCountSongs' on line '[PictureBoxWordCountSongs]' while parsing line number 0 with value '' - IniParser version: 2.5.2.0 + 於 IniParser.Parser.IniDataParser.ProcessSection(String line, IniData currentIniData) + 於 IniParser.Parser.IniDataParser.Parse(String iniDataString) + --- 內部例外狀況堆疊追蹤的結尾 --- + 於 IniParser.Parser.IniDataParser.Parse(String iniDataString) + 於 DualScreenDemo.PrimaryForm.LoadPhoneticSymbolsFromConfig() + 於 DualScreenDemo.PrimaryForm.InitializeButtonsForZhuYinSingers() + 於 DualScreenDemo.PrimaryForm.InitializeFormAndControls() + 於 DualScreenDemo.PrimaryForm..ctor() + 於 DualScreenDemo.Program.Main() +[2025/3/24 上午 10:54:17] System.NullReferenceException: 並未將物件參考設定為物件的執行個體。 + 於 DualScreenDemo.PrimaryForm.LoadSpecialButtonCoordinatesForSongIDSearch(IniData data, String section, String buttonKey) + 於 DualScreenDemo.PrimaryForm.InitializeModifyButtonSongIDSearch() + 於 DualScreenDemo.PrimaryForm.InitializeSpecialButtonsForSongIDSearch() + 於 DualScreenDemo.PrimaryForm.InitializeButtonsForSongIDSearch() + 於 DualScreenDemo.PrimaryForm.InitializeFormAndControls() + 於 DualScreenDemo.PrimaryForm..ctor() + 於 DualScreenDemo.Program.Main() diff --git a/bin/themes/superstar/歌名/字數/4.歌名查詢(字數按鍵)_確認 複本.png b/bin/themes/superstar/歌名/字數/4.歌名查詢(字數按鍵)_確認 複本.png new file mode 100644 index 0000000..4390c4f Binary files /dev/null and b/bin/themes/superstar/歌名/字數/4.歌名查詢(字數按鍵)_確認 複本.png differ diff --git a/bin/themes/superstar/歌名/字數/4.歌名查詢(字數按鍵)_確認.png b/bin/themes/superstar/歌名/字數/4.歌名查詢(字數按鍵)_確認.png new file mode 100644 index 0000000..5727e68 Binary files /dev/null and b/bin/themes/superstar/歌名/字數/4.歌名查詢(字數按鍵)_確認.png differ diff --git a/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-02.png b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-02.png new file mode 100644 index 0000000..8cadd35 Binary files /dev/null and b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-02.png differ diff --git a/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-03.png b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-03.png new file mode 100644 index 0000000..06a97a4 Binary files /dev/null and b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-03.png differ diff --git a/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-04.png b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-04.png new file mode 100644 index 0000000..1d623e5 Binary files /dev/null and b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-04.png differ diff --git a/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-05.png b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-05.png new file mode 100644 index 0000000..90043e8 Binary files /dev/null and b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-05.png differ diff --git a/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-06.png b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-06.png new file mode 100644 index 0000000..99de723 Binary files /dev/null and b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-06.png differ diff --git a/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-07.png b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-07.png new file mode 100644 index 0000000..966468d Binary files /dev/null and b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-07.png differ diff --git a/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-08.png b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-08.png new file mode 100644 index 0000000..1e2434e Binary files /dev/null and b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-08.png differ diff --git a/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-09.png b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-09.png new file mode 100644 index 0000000..699469a Binary files /dev/null and b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-09.png differ diff --git a/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-10.png b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-10.png new file mode 100644 index 0000000..4ec3dc5 Binary files /dev/null and b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-10.png differ diff --git a/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-11.png b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-11.png new file mode 100644 index 0000000..8d81abd Binary files /dev/null and b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-11.png differ diff --git a/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-13.png b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-13.png new file mode 100644 index 0000000..128e38e Binary files /dev/null and b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-13.png differ diff --git a/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-14.png b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-14.png new file mode 100644 index 0000000..193b194 Binary files /dev/null and b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-14.png differ diff --git a/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-15.png b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-15.png new file mode 100644 index 0000000..36d424b Binary files /dev/null and b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-15.png differ diff --git a/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-17.png b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-17.png new file mode 100644 index 0000000..4a8c93a Binary files /dev/null and b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-17.png differ diff --git a/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-18.png b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-18.png new file mode 100644 index 0000000..b0f8421 Binary files /dev/null and b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-18.png differ diff --git a/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-19.png b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-19.png new file mode 100644 index 0000000..5a882be Binary files /dev/null and b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-19.png differ diff --git a/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-20.png b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-20.png new file mode 100644 index 0000000..4b0e27c Binary files /dev/null and b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-20.png differ diff --git a/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-21.png b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-21.png new file mode 100644 index 0000000..1c513ee Binary files /dev/null and b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-21.png differ diff --git a/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-22.png b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-22.png new file mode 100644 index 0000000..6e15c9b Binary files /dev/null and b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-22.png differ diff --git a/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-23.png b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-23.png new file mode 100644 index 0000000..a368c45 Binary files /dev/null and b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-23.png differ diff --git a/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-24.png b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-24.png new file mode 100644 index 0000000..d5bf61a Binary files /dev/null and b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-24.png differ diff --git a/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-25.png b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-25.png new file mode 100644 index 0000000..d2712d4 Binary files /dev/null and b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-25.png differ diff --git a/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-26.png b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-26.png new file mode 100644 index 0000000..7ad23e8 Binary files /dev/null and b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-26.png differ diff --git a/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-28.png b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-28.png new file mode 100644 index 0000000..556f659 Binary files /dev/null and b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-28.png differ diff --git a/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-29.png b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-29.png new file mode 100644 index 0000000..2565b32 Binary files /dev/null and b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-29.png differ diff --git a/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-30.png b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-30.png new file mode 100644 index 0000000..d69b555 Binary files /dev/null and b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)-30.png differ diff --git a/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)_已按.png b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)_已按.png new file mode 100644 index 0000000..9499d41 Binary files /dev/null and b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)_已按.png differ diff --git a/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)_未按.png b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)_未按.png new file mode 100644 index 0000000..82659f1 Binary files /dev/null and b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)_未按.png differ diff --git a/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)_未按_沒有確認.png b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)_未按_沒有確認.png new file mode 100644 index 0000000..5ad4eea Binary files /dev/null and b/bin/themes/superstar/歌名/字數/VOD_歌名查詢_編號查詢(按鍵)_未按_沒有確認.png differ diff --git a/bin/themes/superstar/歌名/編號/VOD_歌名查詢_編號查詢(按鍵)_未按_沒有確認.png b/bin/themes/superstar/歌名/編號/VOD_歌名查詢_編號查詢(按鍵)_未按_沒有確認.png new file mode 100644 index 0000000..0678d1c Binary files /dev/null and b/bin/themes/superstar/歌名/編號/VOD_歌名查詢_編號查詢(按鍵)_未按_沒有確認.png differ diff --git a/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_0 複本.png b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_0 複本.png new file mode 100644 index 0000000..7ad23e8 Binary files /dev/null and b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_0 複本.png differ diff --git a/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_0.png b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_0.png new file mode 100644 index 0000000..8d81abd Binary files /dev/null and b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_0.png differ diff --git a/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_1 複本.png b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_1 複本.png new file mode 100644 index 0000000..4a8c93a Binary files /dev/null and b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_1 複本.png differ diff --git a/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_1.png b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_1.png new file mode 100644 index 0000000..8cadd35 Binary files /dev/null and b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_1.png differ diff --git a/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_2 複本.png b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_2 複本.png new file mode 100644 index 0000000..b0f8421 Binary files /dev/null and b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_2 複本.png differ diff --git a/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_2.png b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_2.png new file mode 100644 index 0000000..06a97a4 Binary files /dev/null and b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_2.png differ diff --git a/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_3 複本.png b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_3 複本.png new file mode 100644 index 0000000..5a882be Binary files /dev/null and b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_3 複本.png differ diff --git a/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_3.png b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_3.png new file mode 100644 index 0000000..1d623e5 Binary files /dev/null and b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_3.png differ diff --git a/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_4 複本.png b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_4 複本.png new file mode 100644 index 0000000..4b0e27c Binary files /dev/null and b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_4 複本.png differ diff --git a/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_4.png b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_4.png new file mode 100644 index 0000000..90043e8 Binary files /dev/null and b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_4.png differ diff --git a/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_5 複本.png b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_5 複本.png new file mode 100644 index 0000000..1c513ee Binary files /dev/null and b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_5 複本.png differ diff --git a/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_5.png b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_5.png new file mode 100644 index 0000000..99de723 Binary files /dev/null and b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_5.png differ diff --git a/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_6 複本.png b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_6 複本.png new file mode 100644 index 0000000..6e15c9b Binary files /dev/null and b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_6 複本.png differ diff --git a/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_6.png b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_6.png new file mode 100644 index 0000000..966468d Binary files /dev/null and b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_6.png differ diff --git a/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_7 複本.png b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_7 複本.png new file mode 100644 index 0000000..a368c45 Binary files /dev/null and b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_7 複本.png differ diff --git a/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_7.png b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_7.png new file mode 100644 index 0000000..1e2434e Binary files /dev/null and b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_7.png differ diff --git a/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_8 複本.png b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_8 複本.png new file mode 100644 index 0000000..d5bf61a Binary files /dev/null and b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_8 複本.png differ diff --git a/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_8.png b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_8.png new file mode 100644 index 0000000..699469a Binary files /dev/null and b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_8.png differ diff --git a/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_9 複本.png b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_9 複本.png new file mode 100644 index 0000000..d2712d4 Binary files /dev/null and b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_9 複本.png differ diff --git a/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_9.png b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_9.png new file mode 100644 index 0000000..4ec3dc5 Binary files /dev/null and b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_9.png differ diff --git a/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_已按.png b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_已按.png new file mode 100644 index 0000000..57c6ef2 Binary files /dev/null and b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_已按.png differ diff --git a/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_未按.png b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_未按.png new file mode 100644 index 0000000..a6f0102 Binary files /dev/null and b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_未按.png differ diff --git a/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_清除 複本.png b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_清除 複本.png new file mode 100644 index 0000000..556f659 Binary files /dev/null and b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_清除 複本.png differ diff --git a/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_清除.png b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_清除.png new file mode 100644 index 0000000..128e38e Binary files /dev/null and b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_清除.png differ diff --git a/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_確認 複本.png b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_確認 複本.png new file mode 100644 index 0000000..4390c4f Binary files /dev/null and b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_確認 複本.png differ diff --git a/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_確認.png b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_確認.png new file mode 100644 index 0000000..5727e68 Binary files /dev/null and b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_確認.png differ diff --git a/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_重填 複本.png b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_重填 複本.png new file mode 100644 index 0000000..2565b32 Binary files /dev/null and b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_重填 複本.png differ diff --git a/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_重填.png b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_重填.png new file mode 100644 index 0000000..193b194 Binary files /dev/null and b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_重填.png differ diff --git a/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_關閉 複本.png b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_關閉 複本.png new file mode 100644 index 0000000..d69b555 Binary files /dev/null and b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_關閉 複本.png differ diff --git a/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_關閉.png b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_關閉.png new file mode 100644 index 0000000..36d424b Binary files /dev/null and b/bin/themes/superstar/歌星/字數/3.歌星查詢(字數按鍵)_關閉.png differ diff --git a/config.ini b/config.ini index 5e09827..51f5f49 100644 --- a/config.ini +++ b/config.ini @@ -46,12 +46,6 @@ Y = 350 Width = 1079 Height = 394 -[PictureBoxWordCountSongs] -X = 130 -Y = 350 -Width = 1079 -Height = 394 - [PhoneticSymbols] Symbols=ㄅ,ㄉ,ㄍ,ㄐ,ㄓ,ㄗ,ㄛ,ㄡ,ㄤ,ㄧ,ㄆ,ㄊ,ㄎ,ㄑ,ㄔ,ㄘ,ㄜ,ㄢ,ㄦ,ㄨ,ㄇ,ㄋ,ㄏ,ㄒ,ㄕ,ㄙ,ㄞ,ㄣ,ㄩ,ㄈ,ㄌ, ,ㄖ,ㄚ,ㄠ @@ -117,6 +111,12 @@ closeButtonPinYinSongs = 1091,642,94,87 refillButtonHandWritingSongs = 918,372,70,65 clearButtonHandWritingSongs = 996,372,70,65 closeButtonForSongs = 1074,372,70,65 +modifyButtonWordCountSongs = 811,643,94,87 +clearButtonWordCountSongs = 692,643,93,87 +closeButtonWordCountSongs = 1051,643,94,87 +modifyButtonSongIDSearch = 811,643,94,87 +clearButtonSongIDSearch = 692,643,93,87 +closeButtonSongIDSearch = 1051,643,94,87 [ModifyButtonImagesZhuYin] normal = themes\superstar\歌星\注音\VOD_歌星查詢_注音查詢(按鍵)-38.png @@ -605,31 +605,39 @@ FontSize = 26 FontStyle = Regular ForeColor = Black +[PictureBoxWordCountSongs] +X = 650 +Y = 300 +Width = 554 +Height = 442 + [InputBoxWordCountSongs] -X=150 -Y=264 -Width=596 -Height=63 -FontName=微軟正黑體 -FontSize=26 -FontStyle=Bold -ForeColor=Black +X = 660 +Y = 370 +Width = 530 +Height = 63 +FontName = Times New Roman +FontSize = 26 +FontStyle = Regular +ForeColor = Black +[NumberWordCountSymbols] +Symbols=1,2,3,4,5,6,7,8,9,0 -[NumberButtonCoordinatesWithWordCount] -button1 = 157,201,27,32 -button2 = 187,201,27,32 -button3 = 217,201,27,32 -button4 = 247,201,27,32 -button5 = 277,200,27,32 -button6 = 307,201,27,32 -button7 = 337,201,27,32 -button8 = 367,201,27,32 -button9 = 397,201,27,32 -button10 = 427,201,27,32 +[NumberWordCountButtonCoordinates] +button0 = 650,300,94,87 +button1 = 660,445,94,87 +button2 = 770,445,94,87 +button3 = 880,445,94,87 +button4 = 990,445,94,87 +button5 = 1100,445,94,87 +button6 = 660,545,94,87 +button7 = 770,545,94,87 +button8 = 880,545,94,87 +button9 = 990,545,94,87 +button10 = 1100,545,94,87 - -[NumberButtonImagesWithWordCount] +[NumberWordCountButtonImages] button0_normal = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-02.png button0_mouseDown = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-17.png button0_mouseOver = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-02.png @@ -662,16 +670,97 @@ button9_mouseDown = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢 button9_mouseOver = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-11.png [ModifyButtonImagesWordCount] -normal = themes\superstar\歌星\拼音\VOD_歌名查詢_編號查詢(按鍵)-13.png -mouseOver = themes\superstar\歌星\拼音\VOD_歌名查詢_編號查詢(按鍵)-13.png -mouseDown = themes\superstar\歌星\拼音\VOD_歌名查詢_編號查詢(按鍵)-28.png +normal = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-13.png +mouseOver = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-13.png +mouseDown = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-28.png [ClearButtonImagesWordCount] -normal = themes\superstar\歌名\拼音\VOD_歌名查詢_編號查詢(按鍵)-14.png -mouseOver = themes\superstar\歌名\拼音\VOD_歌名查詢_編號查詢(按鍵)-14.png -mouseDown = themes\superstar\歌名\拼音\VOD_歌名查詢_編號查詢(按鍵)-29.png +normal = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-14.png +mouseOver = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-14.png +mouseDown = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-29.png [CloseButtonImagesWordCount] -normal = themes\superstar\歌名\拼音\VOD_歌名查詢_編號查詢(按鍵)-15.png -mouseOver = themes\superstar\歌名\拼音\VOD_歌名查詢_編號查詢(按鍵)-15.png -mouseDown = themes\superstar\歌名\拼音\VOD_歌名查詢_編號查詢(按鍵)-30.png \ No newline at end of file +normal = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-15.png +mouseOver = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-15.png +mouseDown = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-30.png + +[PictureBoxSongIDSearch] +X = 650 +Y = 300 +Width = 554 +Height = 442 + +[InputBoxSongIDSearch] +X = 154 +Y = 370 +Width = 593 +Height = 63 +FontName = Times New Roman +FontSize = 26 +FontStyle = Regular +ForeColor = Black + +[NumberSongIDSymbols] +Symbols=1,2,3,4,5,6,7,8,9,0 + +[NumberSongIDButtonCoordinates] +button0 = 650,300,94,87 +button1 = 660,445,94,87 +button2 = 770,445,94,87 +button3 = 880,445,94,87 +button4 = 990,445,94,87 +button5 = 1100,445,94,87 +button6 = 660,545,94,87 +button7 = 770,545,94,87 +button8 = 880,545,94,87 +button9 = 990,545,94,87 +button10 = 1100,545,94,87 + +[NumberSongIDButtonImages] +button0_normal = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-02.png +button0_mouseDown = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-17.png +button0_mouseOver = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-02.png +button1_normal = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-03.png +button1_mouseDown = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-18.png +button1_mouseOver = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-03.png +button2_normal = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-04.png +button2_mouseDown = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-19.png +button2_mouseOver = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-04.png +button3_normal = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-05.png +button3_mouseDown = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-20.png +button3_mouseOver = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-05.png +button4_normal = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-06.png +button4_mouseDown = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-21.png +button4_mouseOver = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-06.png +button5_normal = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-07.png +button5_mouseDown = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-22.png +button5_mouseOver = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-07.png +button6_normal = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-08.png +button6_mouseDown = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-23.png +button6_mouseOver = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-08.png +button7_normal = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-09.png +button7_mouseDown = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-24.png +button7_mouseOver = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-09.png +button8_normal = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-10.png +button8_mouseDown = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-25.png +button8_mouseOver = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-10.png +button9_normal = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-11.png +button9_mouseDown = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-26.png +button9_mouseOver = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-11.png + +[ModifyButtonImagesSongID] +normal = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-13.png +mouseOver = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-13.png +mouseDown = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-28.png + +[ClearButtonImagesSongID] +normal = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-14.png +mouseOver = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-14.png +mouseDown = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-29.png + +[CloseButtonImagesSongID] +normal = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-15.png +mouseOver = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-15.png +mouseDown = themes\superstar\歌名\編號\VOD_歌名查詢_編號查詢(按鍵)-30.png + +