import java.awt.BorderLayout
import java.awt.Color
import java.awt.Component
import java.awt.Dimension
import java.awt.Font
import java.awt.GradientPaint
import java.awt.Graphics
import java.awt.Graphics2D
import java.awt.RenderingHints
import java.awt.Toolkit
import java.awt.datatransfer.StringSelection
import java.awt.event.ActionEvent
import java.awt.event.ActionListener
import java.io.File
import java.io.FileOutputStream
import java.io.OutputStreamWriter
import java.io.PrintWriter
import java.nio.charset.StandardCharsets
import javax.swing.BorderFactory
import javax.swing.DefaultListModel
import javax.swing.JButton
import javax.swing.JFileChooser
import javax.swing.JFrame
import javax.swing.JLabel
import javax.swing.JList
import javax.swing.JOptionPane
import javax.swing.JPanel
import javax.swing.JScrollPane
import javax.swing.JSplitPane
import javax.swing.JTextArea
import javax.swing.JTextField
import javax.swing.ListSelectionModel
import javax.swing.SwingConstants
import javax.swing.SwingUtilities
import javax.swing.Timer
import javax.swing.WindowConstants
import javax.swing.event.DocumentEvent
import javax.swing.event.DocumentListener
import javax.swing.event.ListSelectionEvent
import javax.swing.event.ListSelectionListener
import scala.collection.mutable.ArrayBuffer
// ================================================================
// BIXUU'S UNIVERSE ? ONE FILE SCALA + JAVA SWING KNOWLEDGE HUB
// Sections: Ganpati, Anime Universe, Maharashtra, Festivals,
// Scientists & Creators, TMKOC Families, Cricket, Business,
// General Knowledge, Class 12 History, Bixuu Jokes, My Projects.
// Uses only the Java JDK Swing/AWT APIs and Scala standard library.
// ================================================================
object BixuuUniverse {
final case class Article(title: String, body: String)
final case class Section(title: String, subtitle: String, entries: Vector[Article])
private val BG = new Color(8, 12, 27)
private val PANEL = new Color(17, 25, 47)
private val PANEL2 = new Color(24, 35, 64)
private val PANEL3 = new Color(31, 43, 76)
private val CYAN = new Color(91, 224, 245)
private val PURPLE = new Color(169, 129, 255)
private val GOLD = new Color(255, 210, 112)
private val TEXT = new Color(241, 246, 255)
private val MUTED = new Color(171, 187, 218)
private val GREEN = new Color(116, 229, 174)
private val jokes = Vector(
Article("JOKE 01 ? Jethalal", "Marathi: Jethalal: ????? ??? ???? ??????? ??? ?? ?? ?????? ?????????? ??? ?????!?\nHindi: Jethalal: ?Mera phone itna smart hai ki charger dhoondhte-dhoondhte woh khud so jaata hai!?"),
Article("JOKE 02 ? Bhide", "Marathi: Bhide ?? ????????? ????????? ???? ?????. Tapu Sena ???????, ???, ?? ???????? GST ??????\nHindi: Bhide ne budget mein hasi ka column banaya. Tapu Sena boli, ?Sir, laughter par GST kitna??"),
Article("JOKE 03 ? Tapu Sena", "Marathi: ??????: ????????? ???? ????? Tapu Sena: ??, ????????? ????. ??????: ?? ????? Tapu Sena: ?? ?? group project!\nHindi: Teacher: Project kisne banaya? Tapu Sena: Sabne. Teacher: Naam kisne likhe? Tapu Sena: Woh bhi group project!"),
Article("JOKE 04 ? Popatlal", "Marathi: Popatlal ?? ??????? ???????, ??? ?????????? ???? ?????? ???? ?????: ????? ??? ???!?\nHindi: Popatlal ne chhatri se poocha, ?Hamesha saath dogi?? Chhatri boli, ?Rainy season mein pakka!?"),
Article("JOKE 05 ? Iyer", "Marathi: Iyer: ?? ?? ?????? ?????. Babita: ?????? Iyer: ??? ? ????? ???? ??????? ?? ??!\nHindi: Iyer: Aaj experiment karunga. Babita: Kaunsa? Iyer: Chai ko bina hilaye sugar dissolve hoti hai kya!"),
Article("JOKE 06 ? Hathi Family", "Marathi: Goli: ?? ?? salad ?????. Hathi ??????: ???! Goli: ??? pizza ?? lettuce ?????.\nHindi: Goli: Aaj salad khaunga. Doctor Hathi: Great! Goli: Pehle pizza par lettuce rakh deta hoon."),
Article("JOKE 07 ? Sodhi", "Marathi: Sodhi: ???? bike ???? ?????? ??? ?? ??????? ??? ???? ??? ??????? ????? ??????!\nHindi: Sodhi: Meri bike itni fast hai ki petrol pump mujhe dekhte hi ?phir milenge? bolta hai!"),
Article("JOKE 08 ? Abdul", "Marathi: Abdul: ???? ??? ???. ??????: ???? ???? Abdul: ?????? ????? ????? ??? ??? ???? ??!\nHindi: Abdul: Soda thanda hai. Customer: Kitna thanda? Abdul: Sawal sunte hi aapka gala refresh ho gaya!"),
Article("JOKE 09 ? Daya", "Marathi: Daya: ?? ?? ???? ?????? ??????. Jethalal: ??! Daya: ?????? ?? ????????? TV remote ?????!\nHindi: Daya: Aaj ghar mein shanti rahegi. Jethalal: Wah! Daya: Isliye sabke TV remote chhupa diye!"),
Article("JOKE 10 ? Champaklal", "Marathi: Champaklal: ???????? ????? ????? ????. Jethalal: ?? ???? ????? ???? loading ???\nHindi: Champaklal: Experience se insaan samajhdaar hota hai. Jethalal: Mera experience abhi loading kyun hai?"),
Article("JOKE 11 ? Taarak", "Marathi: Taarak: ?????? ??????? ?? ??? ????? ????. Anjali: ?? ??? ??????? queue ????? ??? ??!\nHindi: Taarak: Dimaag mein bahut thoughts hain. Anjali: Pehle unki queue bana do!"),
Article("JOKE 12 ? Madhavi", "Marathi: Madhavi: ?? ?????? ??? ????. Bhide: ???? Madhavi: ?????? ????? ??????? ?????? ??? ??????!\nHindi: Madhavi: Aaj ghar ka kharcha kam kiya. Bhide: Kaise? Madhavi: Tumhari naye-naye ideas ki shopping band!"),
Article("JOKE 13 ? Sonu", "Marathi: Sonu: ???? ?????? ????? ???? ???. Tapu: ???? ???? Sonu: ??? planner ??????? ??? ???!\nHindi: Sonu: Study plan ready hai. Tapu: Kitne hours? Sonu: Planner decorate karne mein do hours!"),
Article("JOKE 14 ? Babita", "Marathi: Babita: Iyer, ?? ?? online class ????. Iyer: ????? ????? Babita: ????? ????????? ????? ?????!?\nHindi: Babita: Aaj online class lungi. Iyer: Subject? Babita: Ghar mein khoi hui cheezein dhoondhna!"),
Article("JOKE 15 ? Gogi", "Marathi: Gogi: ?? ???? ???????? inventor ?????. Goli: ??? ??????? Gogi: Homework ????? ????? ?????? pencil!\nHindi: Gogi: Bada hokar inventor banunga. Goli: Kya banaoge? Gogi: Homework khud karne wali pencil!"),
Article("JOKE 16 ? Jethalal", "Marathi: ??????: ??????? discount ??? ??? Jethalal: ???. ??????: ????? Jethalal: ?????? ???????? ?????? smile free!\nHindi: Customer: Discount hai? Jethalal: Haan. Kitna? Aapke sawal ke saath smile free!"),
Article("JOKE 17 ? Bhide", "Marathi: Bhide ?? ????????? ????????, ???? ???!? ?????? ???????, ??? ?? ??????, ??????? ????? ????!?\nHindi: Bhide ne ghadi se kaha, ?Time par chalo!? Ghadi boli, ?Main toh chal rahi hoon, aap late aaye!?"),
Article("JOKE 18 ? Popatlal", "Marathi: Popatlal: ?? ???? ????? headline ?????. ?????: ??? ?????? Popatlal: ?? ?????? ??? ???????!\nHindi: Popatlal: Aaj meri headline banegi. Dost: Kya news? Popatlal: Main aaj time par ghar pahuncha!"),
Article("JOKE 19 ? Hathi", "Marathi: ?????? Hathi: ????? ??????????? ??????. Goli: ?? ?? fridge ?????? ??? ?????!\nHindi: Doctor Hathi: Walking health ke liye achhi hai. Goli: Main roz fridge tak walk karta hoon!"),
Article("JOKE 20 ? Sodhi", "Marathi: Sodhi: ?? ?? gym ?? ????. ?????: ??? workout? Sodhi: Gym ???? ?????????? ????? selfie!\nHindi: Sodhi: Aaj gym gaya. Friend: Workout? Sodhi: Gate tak running, phir selfie!"),
Article("JOKE 21 ? Abdul", "Marathi: Abdul: ??? ??? ???. ??????: ???? ????? Abdul: ??????? ?????????? ???!\nHindi: Abdul: Chai garam hai. Customer: Sugar kitni? Abdul: Aapki baaton jitni meethi!"),
Article("JOKE 22 ? Tapu Sena", "Marathi: Tapu Sena ?? group photo ?????. Camera ???????, ????? ???? ??, ???? memory ?? ????!?\nHindi: Tapu Sena ne group photo li. Camera bola, ?Ek-ek karke aao, meri memory bhi thakti hai!?"),
Article("JOKE 23 ? Iyer", "Marathi: Iyer: ???? science project invisible ???. Jethalal: ????? ????! Iyer: ???? ?????, ?????? ??????!\nHindi: Iyer: Mera science project invisible hai. Jethalal: Dikh hi nahi raha! Iyer: Exactly, experiment successful!"),
Article("JOKE 24 ? Daya", "Marathi: Daya: ?? ?? ???? recipe ????. Jethalal: ??? ???? Daya: ??? ????? ?? ????!?\nHindi: Daya: Aaj nayi recipe banayi. Jethalal: Naam? Daya: ?Jo mile, sab mix!?"),
Article("JOKE 25 ? Champaklal", "Marathi: Champaklal: ??????? ????? ?????. Jethalal: ?? ???? ?????? ??? ??? ??? ?? ?????\nHindi: Champaklal: Kitabein dost hoti hain. Jethalal: Phir meri kitab mujhe roz sula kyun deti hai?"),
Article("JOKE 26 ? Anjali", "Marathi: Anjali: Taarak, ?? healthy snack. Taarak: ???! Anjali: ??????? smile ???? ??.\nHindi: Anjali: Aaj healthy snack. Taarak: Great! Anjali: Cucumber ko smile karke khao."),
Article("JOKE 27 ? Sonu", "Marathi: ??????: ?????? ???? ????? Sonu: library ?????. Tapu: ?? ?? ???? ??????? ????????? ???? ???? ?????!\nHindi: Teacher: Padhai kahan ki? Sonu: Library mein. Tapu: Main bhi tha?maine book ke liye jagah pakdi!"),
Article("JOKE 28 ? Goli", "Marathi: Goli: ?? ?? diet ???? ????. Gogi: ????????? Goli: ??????????, ?? farewell party!\nHindi: Goli: Aaj diet start kar raha hoon. Gogi: Kabse? Goli: Kal se, aaj farewell party!"),
Article("JOKE 29 ? Babita", "Marathi: Babita: Iyer, ?????? ???? ???? ???? Iyer: ?????? ?????????? result ????????? ?? ???? ????!\nHindi: Babita: Iyer, itne shaant kaise? Iyer: Experiment ka result aane tak main bolta nahi!"),
Article("JOKE 30 ? Jethalal", "Marathi: Jethalal: ???? laptop ??? slow ???. Taarak: ??? ???? ?????? ???? ??. Jethalal: ?? ?? ?? ???? ??? ???\nHindi: Jethalal: Laptop bahut slow hai. Taarak: Restart karo. Jethalal: Main bhi?"),
Article("JOKE 31 ? Bhide", "Marathi: Bhide: ???? ????? ???. Sakharam: (???????) ??? ???? parking ??? ???!\nHindi: Bhide: Ghar mein discipline chahiye. Sakharam: Pehle meri parking theek karo!"),
Article("JOKE 32 ? Popatlal", "Marathi: Popatlal: ???? ????? ?????. ?????: ????? Popatlal: ???? ?????????? ??????? ????!\nHindi: Popatlal: Meri chhatri kho gayi. Dost: Kahan? Popatlal: Baarish rukne ke baad dhoondhne gaya!"),
Article("JOKE 33 ? Sodhi", "Marathi: Sodhi: ???? alarm ??? ???? ????. Gogi: ?? ??? ????? Sodhi: ??? ?????? snooze ????!\nHindi: Sodhi: Alarm mujhe uthata nahi. Gogi: Kya karta hai? Sodhi: Khud hi snooze ho jaata hai!"),
Article("JOKE 34 ? Hathi", "Marathi: Goli: ?? ?? ??????. ??????: ?????? Goli: ???????? ???????? ????!\nHindi: Goli: Maine fruit khaya. Doctor: Kaunsa? Goli: Fruit shop ka photo!"),
Article("JOKE 35 ? Abdul", "Marathi: ??????: ???? ???? ??????? ??? Abdul: ?????? ???, ?? ?????? ??????!\nHindi: Customer: Soda itna fizz kyun kar raha hai? Abdul: Khush hai, aaj uski chhutti hai!"),
Article("JOKE 36 ? Tapu", "Marathi: Tapu: ???? homework ???? ????. Sonu: ????? Tapu: ???? ??????? ??????!\nHindi: Tapu: Mera homework gayab ho gaya. Sonu: Kahan? Tapu: Copy mein likha hi nahi tha!"),
Article("JOKE 37 ? Taarak", "Marathi: Taarak: ?? ?? ???? ?????. Jethalal: ??? Taarak: ???? ??????? ???? ???? ???!\nHindi: Taarak: Aaj chup rahunga. Jethalal: Kyun? Taarak: Mere thoughts ko bhi bolne do!"),
Article("JOKE 38 ? Madhavi", "Marathi: Madhavi: ?? ???? ??? ????. Bhide: ????? Madhavi: ?????? lecture ???? paper ??????!\nHindi: Madhavi: Aaj saving ki. Bhide: Kitni? Madhavi: Tumhare lecture ke liye paper bachaya!"),
Article("JOKE 39 ? Iyer", "Marathi: Iyer: ?? time machine ??????. Jethalal: ??? ????? ????? Iyer: ???? ???? ????!\nHindi: Iyer: Time machine bana raha hoon. Jethalal: Kab complete hogi? Iyer: Kal hi ho gayi thi!"),
Article("JOKE 40 ? Daya", "Marathi: Daya: ?? ?? ?? ??? ????. Jethalal: ???! Daya: ??? ????? ???? ??????? ?? ???? ???? ????!\nHindi: Daya: Aaj ghar saaf kiya. Jethalal: Great! Daya: Ab cheezein kahan rakhi, mujhe hi nahi pata!"),
Article("JOKE 41 ? Champaklal", "Marathi: Champaklal: ??? ?????? ???. Jethalal: ?? ???? snooze button ???? ?????? ???\nHindi: Champaklal: Samay anmol hai. Jethalal: Toh mera snooze button itna sasta kyun?"),
Article("JOKE 42 ? Sonu", "Marathi: Sonu: ?? notes color-code ????. Tapu: ????? ??? ???????????? Sonu: ?????????? red alert!\nHindi: Sonu: Notes color-code kiye. Tapu: Answers ka color? Sonu: Tumhare liye red alert!"),
Article("JOKE 43 ? Gogi", "Marathi: Gogi: ???? robot ??? ?????. Goli: ??? ????? Gogi: ???? ??? ??? ??? ????!\nHindi: Gogi: Mera robot smart hai. Goli: Kya karta hai? Gogi: Mera kaam mujhe hi wapas deta hai!"),
Article("JOKE 44 ? Babita", "Marathi: Babita: Iyer, ????? watch ???? ???. Iyer: ????, ?? future time ?????!\nHindi: Babita: Aapki watch ulta hai. Iyer: Nahi, main future time dekh raha hoon!"),
Article("JOKE 45 ? Bhide", "Marathi: Bhide: ?????? ???? ???? ???????????????. Tapu: ?? ??? ??????? period ???\nHindi: Bhide: Ghar mein sab timetable se hota hai. Tapu: Hasi ka period kab hai?"),
Article("JOKE 46 ? Popatlal", "Marathi: Popatlal: ?? ?? ??? positive ???. ?????: ???? Popatlal: ????? ??????????? headline ??? ???!\nHindi: Popatlal: Aaj main positive hoon. Dost: Kaise? Popatlal: Headline pehle se khush hai!"),
Article("JOKE 47 ? Sodhi", "Marathi: Sodhi: ?? ?? ??? ???????. Gogi: ?? ???? ???? ??? Sodhi: ?????? horn ?? ?????? ????!\nHindi: Sodhi: Aaj dheere chalaunga. Gogi: Phir horn itna loud kyun? Sodhi: Usko excitement hai!"),
Article("JOKE 48 ? Hathi", "Marathi: ?????? Hathi: ???? ????? ????. Goli: ?? ?????? ????? ??? ???? ???\nHindi: Doctor Hathi: Paani zyada piyo. Goli: Toh baarish mein khada ho jaun?"),
Article("JOKE 49 ? Abdul", "Marathi: Abdul: ?? ??????? special offer. ??????: ???? Abdul: ???????????????? soda!\nHindi: Abdul: Aaj special offer. Customer: Kya? Abdul: Smile ke saath soda!"),
Article("JOKE 50 ? Gokuldham", "Marathi: ???????? ?????: ????? ?????? ????. ????????? ???????, ??? meeting ??? ???????\nHindi: Society announcement: Kal silence day. Sabne poocha, ?Toh meeting kaun karega??")
)
private val sections: Vector[Section] = Vector(
Section("WELCOME HOME", "Your Bixuu knowledge universe", Vector(
Article("Welcome to Bixuu's Universe", "Namaskar! Welcome to BIXUU'S UNIVERSE.\n\n?? app ?? knowledge, culture, character ??? creator hub ???. Left side ???? ??????? section ?????. Middle list ???? topic ????? ??? ??????? scroll ???? ????.\n\nIncluded: Ganpati Bappa ? Anime Universe ? Maharashtra 6 Divisions ? Indian Festivals ? Scientists & Creators ? TMKOC Families ? Cricket Teams ? Business Guidance ? General Knowledge ? Class 12 History ? Bixuu Jokes ? Uploaded Project Index.\n\nSearch box current section ???? topics ?????. PREVIOUS / NEXT ?? entries ????? ?????. COPY ??? SAVE ?? ??????? ??? copy ????? TXT ????? save ???? ????."),
Article("Important Note", "?? learning / fan-guide app ???. TMKOC ??? anime sections ?? fan-made informational summaries ????; TV episodes, scripts ????? official dialogues ?????. Cricket squads ?????? saved code ???? examples ??? ?????, ???????? ??????? current official roster ???? ???. Business section ?? education guide ???; live market prices ????? guaranteed profit ??? ????."),
Article("How to use", "1) Left menu ???? section ?????.\n2) Search box ????? ??? ???? ???.\n3) Middle list ???? topic ?????.\n4) ?????? reader ????? ?????? scroll ???? ????.\n5) PREVIOUS / NEXT ?? ????? ????? ????? topic ????.\n6) COPY TEXT ????? SAVE TXT ?????.\n7) Business section ???? BUILD MY IDEA ?????? ??????? simple business plan ???? ???.")
)),
Section("GANPATI BAPPA", "Ganesh Utsav ? Maharashtra culture ? respectful guide", Vector(
Article("Ganesh Chaturthi ? Overview", "Ganesh Chaturthi ?? ????? ????????? ???????????? ??????? ?? ???. ???????????? ?????? ??? ????????? ????? ?????? ????????? ????? ????. ????, ??????, ?????, ???, community ??? ???? ????? ??????? ????.\n\nBixuu Guide: ???????? ???? ?????? ???? ???????? ???, ????????, noise limits ??? ??????? ?????????? ???? ????."),
Article("Ganpati ? Symbols and Meaning", "????????? ???????? ??????, ?????, ???? ???????, ???? ??? ???????? ??????????? ????? ????????? ?????? ?????. ???? ??? ?????????? ???????? ???? ?????; ???? ????? ????? ????? ?????? ????? ????.\n\n?? ??????? ??? ?????????? ???? ?????????? ?????????/???????? ??????? ??????? ??????? ??? ?????."),
Article("Maharashtra Public Utsav History", "?????????????? ????????? ?????????????? ??????????? ???????? ??? ?????? ???? ????? ?????? ????????? ????? ????. ????????? ?????????? ???????? ??? ????? ????, ?????????? ????????? ??? ??????? ????? ?????.\n\n?????? ??????? ???????? ???????? ????? ??? ??????? ?????? ????? ????? ???."),
Article("Eco-friendly Celebration", "? ???? ??????? ???????? ?????? ?????? ?????.\n? ?????????? ?????? ?????? ?????? ??????? ?????.\n? ????????? ??? ???? ??????? ???? ???.\n? ??????? ???????????? ??????? ??? ????? ?????? ??????? ???? ?????.\n? ??????, ?????? ??? ????????? ???? ?????? ????.\n? ?????? ????????? ?????????? ?????????, ????????, ???? ??? ???? ?????? ???."),
Article("Ganpati Utsav ? Family and Community", "?????? ???? ??? ????????? ?????? ?????????? ???????? ?????? ???? ????. ????????, ???? ???? ??? ???????? ?????????? ?????? ???????? ???. ????????? ?????? ????/???????? ?????? ???????????? ???. ???????? ?????? ??? ?????? ????? ?????????? ??."),
Article("Bixuu Ganpati Creator Corner", "Create your own Ganpati festival page: 1) Theme ????? ? Nature, Art, Music, Learning ????? Community Service. 2) ??????/??????? schedule ????. 3) Waste-reduction plan ???? ???. 4) Drawing, rangoli, quiz ????? history display ????. 5) ??????? ???? ??? family guidance ?????.\n\n?? Library ????? ???????? ???? Ganpati Scala source ?????? ????; ?????? ?? module ??????? ???? ?????? Ganpati guide ??? creator template ???.")
)),
Section("ANIME UNIVERSE", "Saved Bixuu Anime Enemies Story Lab ? character guide", Vector(
Article("Jujutsu Kaisen Universe", "Saved Bixuu anime project ????? JUJUTSU KAISEN universe ???.\n\nMain / story characters: Yuji Itadori, Megumi Fushiguro, Satoru Gojo.\nFeatured characters from uploaded code: Sukuna, Mahito, Toji.\n\nSukuna ? major antagonist; fictional cursed-energy abilities.\nMahito ? antagonist; supernatural soul-related fictional ability.\nToji ? human combat specialist in the fictional setting.\n\n?? fictional character profiles ????. Abilities ?? anime fantasy ?????? ?????????."),
Article("Demon Slayer Universe", "Saved Bixuu anime source ???? DEMON SLAYER section.\n\nMain characters: Tanjiro Kamado, Zenitsu Agatsuma, Inosuke Hashibira.\nFeatured characters: Muzan Kibutsuji, Akaza, Doma.\n\nTanjiro ? kind-hearted learner who values family and compassion.\nZenitsu ? anxious but loyal friend.\nInosuke ? energetic and competitive.\nMuzan, Akaza ??? Doma ?? story antagonists ????.\n\nCharacter arcs, friendship ??? courage ???? focus ???; graphic scenes ?????."),
Article("Attack on Titan Universe", "Saved Bixuu anime source ???? ATTACK ON TITAN section.\n\nMain characters: Eren Yeager, Armin Arlert, Mikasa Ackerman, Levi Ackerman.\nFeatured characters from uploaded code: Beast Titan, Reiner, Annie.\n\n?? series ????? freedom, identity, history, trust ??? difficult choices ?? themes ????. Character ?????? ?? fictional story context ????? ????."),
Article("Naruto Shippuden Universe", "Saved Bixuu anime source ???? NARUTO SHIPPUDEN section.\n\nMain characters: Naruto Uzumaki, Sasuke Uchiha, Sakura Haruno, Kakashi Hatake.\nFeatured characters from uploaded code: Madara, Pain, Obito.\n\nThemes: friendship, teamwork, responsibility, belonging ??? personal growth. Fictional powers ?? real-world instructions ?????? ?????? ??? ???."),
Article("Bixuu Original Anime Crew", "Uploaded BIXUU 02 ? Anime Enemies Story Lab ????? BIX-02 ROBOT ??? NARRATOR ?? story roles ??????.\n\nSuggested original crew: Bixuu (team explorer), BIX-02 (friendly guide robot), Narrator (story voice), Yuji / Tanjiro / Naruto-inspired original heroes??? ??????? ???? ????, designs ??? backstories ???? ???. Existing anime characters ?? official designs copy ? ???? original fan-inspired characters ????."),
Article("Anime Character Creator Guide", "Character ???????: 1) Original ??? ????. 2) Personality ????. 3) Goal ??? challenge ????. 4) Friendship / teamwork ????? mystery ????? theme ?????. 5) Fictional ability ?? non-graphic, fantasy level ?? ????? ???. 6) ??????? dialogues ??? visual design ????.\n\nCopyright note: ?? guide ??? summaries ??????? ???????? ????; anime episodes ????? scripts ?????.")
)),
Section("MAHARASHTRA ? 6 DIVISIONS", "36 districts ? current division reference", Vector(
Article("Konkan Division ? 7 Districts", "Konkan Division: Mumbai City, Mumbai Suburban, Thane, Palghar, Raigad, Ratnagiri, Sindhudurg.\n\nRegion guide: Arabian Sea coastline, ports, beaches, forts, fishing communities, Konkan railway route and coastal ecology.\n\nDistrict administration, boundary labels ??? local details ???? Maharashtra Government sources ?????."),
Article("Pune Division ? 5 Districts", "Pune Division: Pune, Satara, Sangli, Solapur, Kolhapur.\n\nRegion guide: Western Maharashtra; education, industry, sugar and agriculture, forts, cultural traditions and urban growth.\n\nDistrict names are listed as a learning reference; taluka-level data ????? ??? ????."),
Article("Nashik Division ? 5 Districts", "Nashik Division: Nashik, Dhule, Nandurbar, Jalgaon, Ahilyanagar.\n\nRegion guide: Godavari basin, vineyards and agriculture, tribal culture, historical sites and pilgrimage locations.\n\nAhilyanagar is the updated district name previously known as Ahmednagar."),
Article("Chhatrapati Sambhajinagar Division ? 8 Districts", "Chhatrapati Sambhajinagar Division: Chhatrapati Sambhajinagar, Jalna, Beed, Latur, Dharashiv, Nanded, Parbhani, Hingoli.\n\nRegion guide: Marathwada's history, forts, literature, agriculture and cultural heritage.\n\nDharashiv was formerly known as Osmanabad; Chhatrapati Sambhajinagar was formerly known as Aurangabad."),
Article("Amravati Division ? 5 Districts", "Amravati Division: Amravati, Akola, Washim, Buldhana, Yavatmal.\n\nRegion guide: Vidarbha's cotton-growing areas, forest and wildlife, agriculture, historical places and local traditions."),
Article("Nagpur Division ? 6 Districts", "Nagpur Division: Nagpur, Wardha, Bhandara, Gondia, Chandrapur, Gadchiroli.\n\nRegion guide: Central India connectivity, forests, tiger landscapes, minerals, agriculture and historical movements."),
Article("All Six Divisions ? Quick Count", "Konkan 7 + Pune 5 + Nashik 5 + Chhatrapati Sambhajinagar 8 + Amravati 5 + Nagpur 6 = 36 districts.\n\nMaharashtra has six revenue divisions and 36 districts according to state overview information. Official administrative lists can change, so verify before using this as legal or government paperwork."),
Article("Maharashtra Learning Guide", "Study order: 1) Learn six division names. 2) Memorise district names by division. 3) Find divisional headquarters on a map. 4) Note major rivers, crops, industries and heritage. 5) Compare coastal Konkan, western plateau, Marathwada and Vidarbha.\n\nPractice: ???????? division ???? 2 districts map ?? mark ???.")
)),
Section("INDIAN FESTIVALS", "Major festivals across regions ? dates can vary", Vector(
Article("Ganesh Chaturthi", "Lord Ganesha's festival, widely celebrated in Maharashtra and other parts of India. Community worship, decorations, music, cultural programmes and visarjan traditions are common. Lunar-calendar dates vary each year."),
Article("Diwali / Deepavali", "Festival of lights celebrated in many regions with regional stories and traditions. Families decorate homes, share sweets and spend time together. Celebrate responsibly and follow local fire-safety rules."),
Article("Holi", "Spring festival known for colours and community celebrations. Respect consent, use skin-safe colours, protect animals and avoid throwing colours or water at people who do not wish to participate."),
Article("Navratri and Durga Puja", "Nine nights of devotion and cultural programmes in many parts of India. Garba and Dandiya are popular in Gujarat and western India; Durga Puja has major traditions in Bengal and other regions."),
Article("Gudi Padwa and Ugadi", "Regional New Year celebrations in Maharashtra and parts of southern India. They mark new beginnings and are associated with family gatherings and traditional foods."),
Article("Makar Sankranti / Pongal", "Harvest-season celebrations across regions. Makar Sankranti is associated with the Sun's transition; Pongal is an important Tamil harvest festival. Traditions and dates differ regionally."),
Article("Onam and Vishu", "Kerala festivals associated with harvest, family gatherings, flower decorations, feasts and regional cultural traditions."),
Article("Baisakhi and Bihu", "Baisakhi is a harvest and important Sikh celebration in Punjab. Bihu festivals are celebrated in Assam at different times of the agricultural year."),
Article("Janmashtami and Ram Navami", "Festivals marking the birth celebrations of Krishna and Rama in Hindu traditions. Local customs include prayer, devotional music and cultural storytelling."),
Article("Eid al-Fitr and Eid al-Adha", "Important Islamic festivals observed by Muslim communities. Eid al-Fitr follows Ramadan; Eid al-Adha is associated with faith, generosity and sharing. Dates follow the lunar calendar."),
Article("Christmas and Easter", "Christian festivals observed in India and worldwide. Christmas celebrates the birth of Jesus; Easter commemorates the resurrection in Christian belief. Traditions include worship, music and family gatherings."),
Article("Gurpurab", "Sikh festivals commemorating the lives and teachings of Sikh Gurus. Community service, prayer, kirtan and langar are important parts of many celebrations."),
Article("Chhath Puja", "A major festival in Bihar, Jharkhand, eastern Uttar Pradesh and communities elsewhere, dedicated to worship of the Sun and expressions of gratitude. Follow local waterbody safety rules."),
Article("Mahashivratri and Guru Purnima", "Mahashivratri is an important Hindu observance dedicated to Shiva. Guru Purnima honours teachers and guides across several Indian traditions."),
Article("Regional Festivals ? More Examples", "Other important festivals include Losar, Hornbill Festival, Nuakhai, Vishu, Puthandu, Karthigai Deepam, Bathukamma, Bonalu, Teej, Gangaur, Raksha Bandhan, Dussehra, Vasant Panchami, Buddha Purnima and Mahavir Jayanti.\n\nIndia has many local and tribal festivals too; this is a major-festival starter list, not a complete list of every community celebration."),
Article("Festival Respect and Safety Guide", "Respect different faiths and customs. Ask before taking photos. Do not pressure anyone to join. Keep public spaces clean, avoid waste, use safe decorations, stay with trusted adults in crowded places, and follow local organiser / government guidance.\n\nOfficial UTSAV portal: https://utsav.gov.in/ ? it lists festivals and events across states and is updated over time.")
)),
Section("INDIAN SCIENTISTS & CREATORS", "People, discoveries, ideas and learning guidance", Vector(
Article("Dr. A. P. J. Abdul Kalam", "Aerospace scientist and the 11th President of India (2002?2007). He contributed to India's space and missile research programmes and inspired students through education and public service.\n\nStudy keywords: ISRO, SLV-III, science education, public service, President of India."),
Article("C. V. Raman", "Physicist who discovered the Raman Effect, explaining how light changes wavelength when scattered by matter. He received the 1930 Nobel Prize in Physics.\n\nStudy keywords: optics, light scattering, Nobel Prize."),
Article("Homi J. Bhabha", "Physicist and institution builder who played a major role in developing India's atomic-energy research ecosystem.\n\nStudy keywords: theoretical physics, TIFR, atomic research institutions."),
Article("Vikram Sarabhai", "Physicist widely regarded as a key founder of India's space programme. He emphasised the use of space science for national development and practical applications."),
Article("Srinivasa Ramanujan", "Mathematician known for remarkable contributions to number theory, infinite series and mathematical identities. His notebooks continue to inspire mathematical study."),
Article("Satyendra Nath Bose", "Physicist whose work on quantum statistics led to the term Bose-Einstein statistics and the name boson. His work is foundational in modern physics."),
Article("Janaki Ammal", "Botanist and cytogeneticist known for research in plant science, genetics and plant breeding. She is an important figure in Indian scientific history."),
Article("M. S. Swaminathan", "Agricultural scientist who played a leading role in India's Green Revolution and work on food security and agricultural research."),
Article("Verghese Kurien", "Engineer and institution builder known for transforming India's dairy cooperative movement. Often associated with Operation Flood and the growth of cooperative dairying."),
Article("Ritu Karidhal", "Indian aerospace engineer associated with ISRO missions, including the Mars Orbiter Mission and Chandrayaan-2. She is often called the 'Rocket Woman of India' in media."),
Article("Tessy Thomas", "Indian scientist and engineer known for leadership roles in missile research and development. Her career is an example of women in science and engineering."),
Article("Dadasaheb Phalke", "Pioneer of Indian cinema, known for directing Raja Harishchandra (1913), an early full-length Indian feature film. The Dadasaheb Phalke Award honours lifetime contribution to Indian cinema."),
Article("Satyajit Ray", "Filmmaker, writer and illustrator whose films and creative work gained international recognition. His work is studied in cinema, storytelling and visual arts."),
Article("Creators ? How to Start", "1) Choose a problem or topic you genuinely care about. 2) Research and credit reliable sources. 3) Make a small prototype. 4) Test it with trusted people. 5) Improve from feedback. 6) Respect copyright and privacy. 7) Describe what your creation can and cannot do honestly."),
Article("Science Project Guidance", "A good school science project includes: a clear question, background research, a safe method, observations, results, conclusion and references. Do not test dangerous chemicals, electrical systems or risky experiments without teacher / adult supervision. Prefer safe models, simulations and everyday observations.")
)),
Section("TMKOC FAMILIES & MEMBERS", "TMKOC / Gokuldham fan guide ? family index", Vector(
Article("Jethalal Gada Family", "Members from the saved Bixuu TMKOC Families Guide: Jethalal Gada, Dayaben Gada, Tipendra 'Tapu' Gada and Champaklal Gada.\n\nGuide note: Jethalal runs an electronics shop; Daya is known for her cheerful style; Tapu leads Tapu Sena; Champaklal is the elder and guide of the family. Actor/cast details can change across seasons and are not a live cast database."),
Article("Atmaram Bhide Family", "Members from saved guide: Atmaram Bhide, Madhavi Bhide, Sonalika 'Sonu' Bhide and Sakharam (the scooter).\n\nBhide is the society secretary and tutor; Madhavi manages a home business; Sonu is a student and part of Tapu Sena. Sakharam is a much-loved scooter in the family's stories."),
Article("Taarak Mehta Family", "Saved guide members: Taarak Mehta and Anjali Mehta.\n\nTaarak is a writer and Jethalal's friend; Anjali is associated with health-conscious food and routines in the show's humour."),
Article("Dr. Hathi Family", "Saved guide members: Dr. Hansraj Hathi, Komal Hathi and Goli Hathi.\n\nThis family is part of Gokuldham's community stories. The guide describes their family roles and friendly society interactions."),
Article("Iyer Family", "Saved guide members: Krishnan Subramaniam Iyer and Babita Iyer.\n\nThe saved code describes Iyer as a scientist and Babita as a professional. Their stories often connect science, friendship and neighbourhood humour."),
Article("Popatlal", "Saved guide names: Patrakar Popatlal Pandey, Durgawati and his umbrella.\n\nPopatlal is a journalist in the show. The umbrella is often treated like a comic companion in fan discussions."),
Article("Sodhi Family", "Saved guide members: Roshan Singh Sodhi, Roshan Bhabhi and Gogi Sodhi.\n\nSodhi is energetic and sociable. Family and society stories often focus on friendship and enthusiasm."),
Article("Abdul and Gokuldham", "Saved guide entry: Abdul, the soda-shop owner and familiar member of Gokuldham Society. His shop is a meeting point for neighbourhood conversations."),
Article("Tapu Sena ? Members Guide", "Names appearing across TMKOC stories and fan guides include Tapu, Sonu, Goli, Gogi and Pinku. The exact group membership and actor cast have varied over time.\n\nUser-requested extra names: Rupa, Bansari and Veer ? kept here as 'check / verify' entries until their character and family details are confirmed from an official episode or cast source."),
Article("Bixuu TMKOC Fan Guide Note", "This is an original fan-made character and family directory based on your saved TMKOC guide. It does not reproduce episodes, scripts or copyrighted dialogue. Use official episode credits for the latest cast and character changes.")
)),
Section("CRICKET TEAMS", "Saved Bixuu cricket project ? teams and learning guide", Vector(
Article("IPL Team Directory", "Teams named in the saved Bixuu cricket code: RCB, CSK, MI, SRH, GT, RR, KKR, PBKS and LSG. Delhi Capitals (DC) is added to complete the ten-team reference list.\n\nThis is a franchise index, not a live tournament table. Team names and competition formats should be checked with the official league website for the current season."),
Article("RCB ? Saved Sample Squad", "The saved Bixuu sample code lists: Virat Kohli, Rajat Patidar, Phil Salt, Jitesh Sharma, Krunal Pandya, Bhuvneshwar Kumar, Yash Dayal, Josh Hazlewood, Nuwan Thushara, Rasikh Salam and Suyash Sharma.\n\nThis is an archived code snapshot, not a guarantee of the current playing squad."),
Article("CSK ? Saved Sample Squad", "The saved Bixuu sample code lists: Ruturaj Gaikwad, MS Dhoni, Devon Conway, Shivam Dube, Ravindra Jadeja, Deepak Chahar, Matheesha Pathirana, Tushar Deshpande, Maheesh Theekshana, Mustafizur Rahman and Ajinkya Rahane.\n\nThis is an archived code snapshot; player availability and squads change by season."),
Article("MI ? Saved Sample Squad", "The saved Bixuu sample code lists: Rohit Sharma, Suryakumar Yadav, Ishan Kishan, Hardik Pandya, Tilak Varma, Jasprit Bumrah, Trent Boult, Mayank Markande, Tim David, Ashwani Kumar and Ryan Rickelton.\n\nArchived sample only ? check official current squad before relying on it."),
Article("Other Teams", "SRH ? Sunrisers Hyderabad\nGT ? Gujarat Titans\nRR ? Rajasthan Royals\nKKR ? Kolkata Knight Riders\nPBKS ? Punjab Kings\nLSG ? Lucknow Super Giants\nDC ? Delhi Capitals\n\nThe saved code included generic squad placeholders for several teams. This hub avoids inventing exact current rosters."),
Article("Cricket Basics ? Match Flow", "A match begins with a toss. The winning captain chooses batting or bowling. Teams take turns batting and bowling. Runs, wickets, overs, extras and target determine the result.\n\nAn over normally contains six legal deliveries. A batter scores runs; bowlers try to restrict runs and take wickets; fielders support the bowling side."),
Article("Player Roles and Stats", "Roles include opening batter, middle-order batter, wicketkeeper, all-rounder, fast bowler, spin bowler and fielder. Common stats: runs, strike rate, batting average, wickets, economy rate, catches and run-outs.\n\nUse official scorecards for live statistics.")
)),
Section("BUSINESS & CREATOR GUIDANCE", "Build an idea ? plan a project ? understand business", Vector(
Article("What is a Business?", "A business offers a product or service that solves a real customer need. It must understand who the customer is, what value it gives, what it costs to operate and how it will communicate honestly.\n\nStart with learning and a small supervised project. For legal, financial or payment decisions, involve a trusted adult."),
Article("Simple Business Plan", "1) Idea: What are you offering?\n2) Customer: Who might use it?\n3) Problem: What need does it solve?\n4) Cost: What materials, time and tools are needed?\n5) Price: How will you estimate a fair price?\n6) Promotion: How can you explain it clearly?\n7) Feedback: What should improve?\n8) Records: Track costs, sales and feedback honestly."),
Article("Small Creator Project Ideas", "? Handmade greeting cards or bookmarks.\n? School event poster design.\n? A simple educational website prototype.\n? A family recipe booklet with permission.\n? A local history mini-guide.\n? A safe recycling awareness campaign.\n\nAvoid collecting personal data, publishing addresses or accepting online payments without adult guidance."),
Article("Marketing and Customer Care", "Good marketing explains real features without false promises. Ask customers for feedback respectfully. Protect private information. Do not spam people. Make refund / delivery conditions clear when applicable. Respect images, music, logos and other creators' rights."),
Article("Bixuu Creator Platform ? Project Workflow", "Your saved DeveloperCreatorPlatform project contains project/prompt/code creation concepts. This integrated guide uses the workflow: IDEA ? TITLE ? CATEGORY ? DESCRIPTION ? PLAN ? BUILD ? TEST ? IMPROVE.\n\nFor a code project, list the runtime, libraries, UI, interactions, error handling and testing steps before building."),
Article("Car and Bike Price Research ? Honest Use", "A saved Bixuu project idea explored car and bike price comparisons. This hub does not have a verified live vehicle-price API connected. Treat any manually entered prices as estimates and check the official manufacturer / dealer listing. Future live price integration needs a licensed data source, API key and terms review."),
Article("Build My Business Idea", "Use the BUILD MY IDEA button below to enter a title, customer and budget estimate. The app creates a draft plan you can copy or save. This is a learning worksheet, not financial or legal advice.")
)),
Section("GENERAL KNOWLEDGE", "Quick facts ? practice questions ? study guide", Vector(
Article("India ? Quick Facts", "India is a federal democratic republic. New Delhi is the national capital. The Constitution came into effect on 26 January 1950. India has many languages, faiths, regions and cultural traditions.\n\nUse current official sources for live office-holders, rankings and changing statistics."),
Article("Science and Space", "ISRO is India's national space agency. Chandrayaan missions study the Moon; Aditya-L1 studies the Sun; Gaganyaan is India's human spaceflight programme. Mission status changes over time, so check ISRO's official updates for the latest."),
Article("Geography", "The Himalayas lie in northern India. The Indian Ocean is to the south; the Arabian Sea lies to the west and Bay of Bengal to the east. The Ganga, Godavari, Krishna, Narmada and Brahmaputra are major river systems."),
Article("Sports", "Cricket, hockey, football, badminton, athletics, kabaddi, wrestling and chess are among sports widely followed in India. Learn the rules, teamwork and fair play. For current results, use official competition scorecards."),
Article("GK Quiz 01", "Q: What is the capital of India?\nA: New Delhi.\n\nQ: Which planet is called the Red Planet?\nA: Mars.\n\nQ: What is the national animal of India?\nA: Bengal tiger.\n\nQ: Which body conducts elections to Parliament and State Legislatures in India?\nA: Election Commission of India."),
Article("GK Quiz 02", "Q: What is the chemical symbol for water?\nA: H?O.\n\nQ: Which is the largest ocean?\nA: Pacific Ocean.\n\nQ: Who wrote the Indian national anthem?\nA: Rabindranath Tagore.\n\nQ: What is the currency of India?\nA: Indian rupee."),
Article("GK Quiz 03", "Q: What is the capital of Maharashtra?\nA: Mumbai.\n\nQ: Which organisation operates India's space programme?\nA: ISRO.\n\nQ: How many revenue divisions does Maharashtra have?\nA: Six.\n\nQ: What is the full form of CPU?\nA: Central Processing Unit."),
Article("Study Tips", "Use active recall: close the page and explain the topic in your own words. Make short notes, practise questions, check facts from trusted sources and revise at spaced intervals. If a fact can change, write the date checked.")
)),
Section("CLASS 12 HISTORY ? PERSONALITIES", "Exam-support guide ? board syllabus may differ", Vector(
Article("Chhatrapati Shivaji Maharaj", "Founder of the Maratha state and a major figure in 17th-century Deccan history. Study his administration, forts, naval policy, diplomacy and the social-political context of the period."),
Article("Ahilyabai Holkar", "Ruler of the Malwa region known for administration, public works and support for temples and pilgrimage infrastructure. Study her governance and legacy."),
Article("Mahatma Jyotirao Phule", "Social reformer who challenged caste discrimination and worked for education and equality. He and Savitribai Phule helped establish schools for girls and marginalised communities."),
Article("Savitribai Phule", "Pioneer of girls' education and social reform in 19th-century India. Study her role in education, equality and anti-caste reform."),
Article("Dr. B. R. Ambedkar", "Constitutional thinker, jurist and social reformer who chaired the Drafting Committee of India's Constitution. Study his work on equality, rights, education and social justice."),
Article("Mahatma Gandhi", "Leader of India's freedom movement who promoted satyagraha and non-violent resistance. Study major movements, political context, methods and criticism from different historical perspectives."),
Article("Jawaharlal Nehru", "A leading figure in the freedom movement and India's first Prime Minister. Study the national movement, parliamentary democracy, planning and foreign policy in the early republic."),
Article("Subhas Chandra Bose", "Nationalist leader who led the Indian National Army movement and advocated a different strategy for independence. Study his political context and historical debate."),
Article("Rani Lakshmibai", "Queen of Jhansi and a prominent figure in the uprising of 1857. Study her leadership and the wider causes and events of the revolt."),
Article("Sardar Vallabhbhai Patel", "National leader who played a key role in integrating princely states into the Indian Union after independence. Study diplomacy, administration and national integration."),
Article("Bhagat Singh", "Revolutionary freedom fighter remembered for anti-colonial activism and political writing. Study the organisations, ideas and events of his time without romanticising violence."),
Article("Ashoka", "Mauryan emperor whose inscriptions provide important evidence for ancient Indian history. Study the Kalinga war, dhamma, administration and spread of inscriptions."),
Article("Raja Ram Mohan Roy", "Social and religious reformer associated with efforts against sati and with modern education and reform movements in the 19th century."),
Article("Dadabhai Naoroji", "Early nationalist thinker who developed the Drain Theory to analyse colonial economic extraction. Study his role in public debate and the Indian National Congress."),
Article("Bal Gangadhar Tilak", "Nationalist leader and publicist who promoted political mobilisation and public festivals in Maharashtra. Study his writings, political methods and role in the freedom movement."),
Article("Class 12 History ? Answer Framework", "For each personality, prepare: (1) time period, (2) social / political background, (3) key actions or ideas, (4) impact, (5) historical evidence, (6) balanced conclusion.\n\nThe exact Class 12 syllabus differs by board and year. Match these notes to your official textbook and teacher's syllabus.")
)),
Section("BIXUU JOKES WORLD", "50 original clean fan-made jokes ? Marathi + Hindi", jokes),
Section("MY UPLOADED PROJECTS", "Files discovered in your saved Bixuu project library", Vector(
Article("Anime Enemies Story Lab", "Found source: Pasted markdown (20261005-155935).md. It contains a Bixuu Anime Enemies Story Lab with four anime universes: Jujutsu Kaisen, Demon Slayer, Attack on Titan and Naruto Shippuden, plus character scenes and profiles. This Bixuu Universe app integrates a non-graphic character directory, not the complete original game/story script."),
Article("TMKOC Families & Characters Guide", "Found source: Pasted text (20260926-135425).txt. It includes Jethalal, Bhide, Taarak, Hathi, Iyer, Popatlal, Sodhi and Abdul family/member mapping. This hub uses the saved character-family list and adds a note to verify newer characters from official episode credits."),
Article("Animated Cricket Project", "Found source: Pasted text (20260920-060502).txt. It includes team selection, squads, toss, overs, score, wickets and animated bowling logic. The team names and example squads here are an archived snapshot from that file, not a current roster feed."),
Article("Developer Creator Platform", "Found source: DeveloperCreatorPlatform_CLEAN.scala. It includes project categories, prompt/code creation ideas and a creator workflow. This hub includes a simpler idea-planning guide and interactive business idea builder."),
Article("India RTO / Car-Bike / Train Project", "Found sources: Pasted text (20260926-135702).txt and Pasted text (20260926-135949).txt, plus INDIA_RTO_LIVE_TRAIN_SAME_PASSWORD_BHAVESH2013.scala. These include state codes, RTO codes and a train model. The current hub indexes the project but does not claim live API data is connected."),
Article("Ganpati Module", "No standalone Ganpati source file was returned in the searched Library results. The Ganpati Bappa guide in this build is newly created from general cultural information and safe celebration guidance."),
Article("Indian Festivals / Scientists / GK / History", "No single matching saved source file was located for these sections in the searched results. The guide pages in this build are newly assembled study content. Verify changing information and use your current school / government sources."),
Article("What 'DMCOC' Means Here", "The saved family/member code is titled TMKOC Families & Characters Guide. For this build, the family section is labelled TMKOC. If you meant a different project by 'DMCOC', its exact name or file can be added later.")
))
)
private var frame: JFrame = _
private var sectionList: JList[String] = _
private var articleList: JList[String] = _
private var articleModel: DefaultListModel[String] = _
private var searchField: JTextField = _
private var readerArea: JTextArea = _
private var articleTitle: JLabel = _
private var sectionHeading: JLabel = _
private var statusLabel: JLabel = _
private var visibleArticles: Vector[Article] = Vector.empty
private var currentSectionIndex: Int = 0
private var selectedArticleIndex: Int = -1
private var customArticle: Option[Article] = None
private def makeButton(text: String): JButton = {
val b = new JButton(text)
b.setFont(new Font("SansSerif", Font.BOLD, 12))
b.setForeground(TEXT)
b.setBackground(PANEL3)
b.setFocusPainted(false)
b.setBorder(BorderFactory.createCompoundBorder(
BorderFactory.createLineBorder(new Color(75, 105, 158), 1),
BorderFactory.createEmptyBorder(8, 13, 8, 13)))
b.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR))
b
}
private def makeLabel(text: String, size: Int, color: Color, bold: Boolean): JLabel = {
val l = new JLabel(text)
l.setFont(new Font("SansSerif", if (bold) Font.BOLD else Font.PLAIN, size))
l.setForeground(color)
l
}
private class AnimatedHeader extends JPanel {
private var phase = 0.0
private val timer = new Timer(40, new ActionListener {
override def actionPerformed(e: ActionEvent): Unit = {
phase += 0.035
if (phase > 6.28) phase = phase - 6.28
repaint()
}
})
setPreferredSize(new Dimension(900, 118))
setOpaque(true)
timer.start()
override protected def paintComponent(graphics: Graphics): Unit = {
super.paintComponent(graphics)
val g = graphics.create().asInstanceOf[Graphics2D]
try {
g.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_ON)
g.setPaint(new GradientPaint(0, 0, new Color(43, 30, 103), getWidth, getHeight, new Color(8, 104, 133)))
g.fillRect(0, 0, getWidth, getHeight)
var i = 0
while (i < 8) {
val x = (getWidth * (i + 1) / 9.0 + math.sin(phase + i * 0.7) * 22).toInt
val y = (18 + ((i * 19) % 75) + math.cos(phase * 1.3 + i) * 7).toInt
val alpha = (55 + (math.sin(phase + i) * 35).toInt).max(15).min(110)
g.setColor(new Color(180, 238, 255, alpha))
g.fillOval(x, y, 4 + (i % 3), 4 + (i % 3))
i += 1
}
g.setColor(new Color(255, 255, 255, 24))
g.fillOval(getWidth - 210, -75, 250, 250)
g.setColor(new Color(255, 255, 255, 16))
g.fillOval(getWidth - 165, -30, 180, 180)
g.setFont(new Font("SansSerif", Font.BOLD, 27))
g.setColor(Color.WHITE)
g.drawString("BIXUU'S UNIVERSE", 28, 46)
g.setFont(new Font("SansSerif", Font.PLAIN, 13))
g.setColor(new Color(223, 243, 255))
g.drawString("Culture ? Characters ? Knowledge ? Creativity", 31, 72)
g.setFont(new Font("SansSerif", Font.BOLD, 10))
g.setColor(new Color(161, 255, 225))
g.drawString("SCALA + SWING EDITION", 31, 94)
} finally {
g.dispose()
}
}
}
private def updateStatus(message: String): Unit = {
if (statusLabel != null) statusLabel.setText(" " + message)
}
private def currentArticle: Option[Article] = {
customArticle.orElse {
if (selectedArticleIndex >= 0 && selectedArticleIndex < visibleArticles.length) Some(visibleArticles(selectedArticleIndex))
else None
}
}
private def displayArticle(index: Int): Unit = {
customArticle = None
if (index >= 0 && index < visibleArticles.length) {
selectedArticleIndex = index
articleList.setSelectedIndex(index)
val a = visibleArticles(index)
articleTitle.setText(a.title)
readerArea.setText(a.body)
readerArea.setCaretPosition(0)
updateStatus("Reading: " + a.title)
} else {
selectedArticleIndex = -1
articleTitle.setText("Choose a topic")
readerArea.setText("Select an entry from the middle list to read it here.")
}
}
private def filterArticles(): Unit = {
customArticle = None
if (currentSectionIndex < 0 || currentSectionIndex >= sections.length) return
val q = if (searchField == null) "" else searchField.getText.trim.toLowerCase
val source = sections(currentSectionIndex).entries
visibleArticles = if (q.isEmpty) source else source.filter { a =>
(a.title + " " + a.body).toLowerCase.contains(q)
}
articleModel.clear()
visibleArticles.foreach(a => articleModel.addElement(a.title))
if (visibleArticles.nonEmpty) displayArticle(0)
else {
selectedArticleIndex = -1
articleTitle.setText("No matching topic")
readerArea.setText("No result in this section. Search another word or choose a different category.")
updateStatus("No matches")
}
if (sectionHeading != null) sectionHeading.setText(sections(currentSectionIndex).title + " ? " + visibleArticles.length + " topics")
}
private def loadSection(index: Int): Unit = {
if (index >= 0 && index < sections.length) {
currentSectionIndex = index
val s = sections(index)
if (sectionHeading != null) sectionHeading.setText(s.title + " ? " + s.subtitle)
if (searchField != null) searchField.setText("")
filterArticles()
updateStatus("Opened " + s.title)
}
}
private def copyCurrent(): Unit = {
currentArticle match {
case Some(a) =>
try {
val text = a.title + "\n\n" + a.body
Toolkit.getDefaultToolkit.getSystemClipboard.setContents(new StringSelection(text), null)
updateStatus("Copied " + a.title)
} catch {
case ex: Exception => updateStatus("Clipboard unavailable: " + ex.getMessage)
}
case None => updateStatus("Choose an article first")
}
}
private def saveCurrent(): Unit = {
currentArticle match {
case Some(a) =>
val chooser = new JFileChooser()
chooser.setDialogTitle("Save Bixuu article as TXT")
chooser.setSelectedFile(new File(a.title.replaceAll("[^A-Za-z0-9-]", "_") + ".txt"))
val result = chooser.showSaveDialog(frame)
if (result == JFileChooser.APPROVE_OPTION) {
var out: PrintWriter = null
try {
out = new PrintWriter(new OutputStreamWriter(new FileOutputStream(chooser.getSelectedFile), StandardCharsets.UTF_8))
out.println(a.title)
out.println("=" * math.max(8, a.title.length))
out.println()
out.println(a.body)
updateStatus("Saved " + chooser.getSelectedFile.getName)
} catch {
case ex: Exception => updateStatus("Save failed: " + ex.getMessage)
} finally {
if (out != null) out.close()
}
}
case None => updateStatus("Choose an article first")
}
}
private def buildBusinessIdea(): Unit = {
val nameField = new JTextField(20)
val customerField = new JTextField(20)
val needField = new JTextField(20)
val budgetField = new JTextField("Estimate only", 20)
val panel = new JPanel(new java.awt.GridLayout(0, 2, 8, 8))
panel.add(makeLabel("Project / Business Name", 12, TEXT, true)); panel.add(nameField)
panel.add(makeLabel("Who is it for?", 12, TEXT, true)); panel.add(customerField)
panel.add(makeLabel("What need does it solve?", 12, TEXT, true)); panel.add(needField)
panel.add(makeLabel("Estimated budget (optional)", 12, TEXT, true)); panel.add(budgetField)
val result = JOptionPane.showConfirmDialog(frame, panel, "BIXUU CREATOR ? BUILD MY IDEA", JOptionPane.OK_CANCEL_OPTION, JOptionPane.PLAIN_MESSAGE)
if (result == JOptionPane.OK_OPTION) {
val plan = "BIXUU ? MY IDEA PLAN\n\nNAME: " + nameField.getText.trim +
"\nCUSTOMER: " + customerField.getText.trim +
"\nNEED: " + needField.getText.trim +
"\nBUDGET NOTE: " + budgetField.getText.trim +
"\n\nNEXT STEPS\n1. Research the need and ask for feedback.\n2. Make a small safe prototype.\n3. List costs and time honestly.\n4. Improve after testing.\n5. Ask a trusted adult before payments, contracts or public launch.\n\nThis is an educational draft, not financial or legal advice."
customArticle = Some(Article("My Bixuu Idea Plan", plan))
readerArea.setText(plan)
articleTitle.setText("My Bixuu Idea Plan")
readerArea.setCaretPosition(0)
updateStatus("Idea plan created ? use SAVE TXT to keep it")
}
}
private def buildUI(): Unit = {
frame = new JFrame("BIXUU'S UNIVERSE ? Scala Swing")
frame.setDefaultCloseOperation(WindowConstants.EXIT_ON_CLOSE)
frame.setMinimumSize(new Dimension(1020, 700))
frame.setSize(1360, 860)
frame.setLocationRelativeTo(null)
val root = new JPanel(new BorderLayout(12, 12))
root.setBackground(BG)
root.setBorder(BorderFactory.createEmptyBorder(12, 12, 10, 12))
val header = new AnimatedHeader()
root.add(header, BorderLayout.NORTH)
val navPanel = new JPanel(new BorderLayout(8, 8))
navPanel.setBackground(PANEL)
navPanel.setBorder(BorderFactory.createCompoundBorder(
BorderFactory.createLineBorder(new Color(52, 75, 120)),
BorderFactory.createEmptyBorder(12, 10, 12, 10)))
navPanel.setPreferredSize(new Dimension(235, 600))
navPanel.add(makeLabel("UNIVERSE MENU", 13, CYAN, true), BorderLayout.NORTH)
val sectionModel = new DefaultListModel[String]()
sections.foreach(s => sectionModel.addElement(s.title))
sectionList = new JList[String](sectionModel)
sectionList.setSelectionMode(ListSelectionModel.SINGLE_SELECTION)
sectionList.setFont(new Font("SansSerif", Font.BOLD, 12))
sectionList.setBackground(PANEL2)
sectionList.setForeground(TEXT)
sectionList.setSelectionBackground(new Color(62, 91, 155))
sectionList.setSelectionForeground(Color.WHITE)
sectionList.setFixedCellHeight(34)
navPanel.add(new JScrollPane(sectionList), BorderLayout.CENTER)
val navFoot = new JPanel(new BorderLayout(4, 4))
navFoot.setOpaque(false)
navFoot.add(makeLabel("Choose any world to explore.", 10, MUTED, false), BorderLayout.NORTH)
val buildButton = makeButton("BUILD MY IDEA")
navFoot.add(buildButton, BorderLayout.SOUTH)
navPanel.add(navFoot, BorderLayout.SOUTH)
val center = new JPanel(new BorderLayout(10, 10))
center.setBackground(BG)
val topBar = new JPanel(new BorderLayout(8, 8))
topBar.setBackground(PANEL)
topBar.setBorder(BorderFactory.createEmptyBorder(10, 12, 10, 12))
sectionHeading = makeLabel("WELCOME HOME", 17, GOLD, true)
topBar.add(sectionHeading, BorderLayout.WEST)
searchField = new JTextField()
searchField.setToolTipText("Search topics in this section")
searchField.setFont(new Font("SansSerif", Font.PLAIN, 12))
searchField.setBackground(PANEL2)
searchField.setForeground(TEXT)
searchField.setCaretColor(Color.WHITE)
searchField.setBorder(BorderFactory.createCompoundBorder(BorderFactory.createLineBorder(new Color(64, 91, 140)), BorderFactory.createEmptyBorder(7, 9, 7, 9)))
searchField.setPreferredSize(new Dimension(260, 34))
topBar.add(searchField, BorderLayout.EAST)
center.add(topBar, BorderLayout.NORTH)
val articleModelLocal = new DefaultListModel[String]()
articleModel = articleModelLocal
articleList = new JList[String](articleModel)
articleList.setSelectionMode(ListSelectionModel.SINGLE_SELECTION)
articleList.setFont(new Font("SansSerif", Font.PLAIN, 13))
articleList.setBackground(PANEL2)
articleList.setForeground(TEXT)
articleList.setSelectionBackground(new Color(61, 84, 145))
articleList.setSelectionForeground(Color.WHITE)
articleList.setFixedCellHeight(31)
val listPanel = new JPanel(new BorderLayout(8, 8))
listPanel.setBackground(PANEL)
listPanel.setBorder(BorderFactory.createCompoundBorder(BorderFactory.createLineBorder(new Color(47, 70, 112)), BorderFactory.createEmptyBorder(10, 10, 10, 10)))
listPanel.add(makeLabel("TOPICS / ENTRIES", 12, CYAN, true), BorderLayout.NORTH)
listPanel.add(new JScrollPane(articleList), BorderLayout.CENTER)
val readPanel = new JPanel(new BorderLayout(8, 8))
readPanel.setBackground(PANEL)
readPanel.setBorder(BorderFactory.createCompoundBorder(BorderFactory.createLineBorder(new Color(47, 70, 112)), BorderFactory.createEmptyBorder(14, 14, 12, 14)))
articleTitle = makeLabel("Choose a topic", 20, GOLD, true)
readPanel.add(articleTitle, BorderLayout.NORTH)
readerArea = new JTextArea()
readerArea.setEditable(false)
readerArea.setLineWrap(true)
readerArea.setWrapStyleWord(true)
readerArea.setFont(new Font("SansSerif", Font.PLAIN, 15))
readerArea.setForeground(TEXT)
readerArea.setBackground(new Color(12, 18, 35))
readerArea.setCaretColor(Color.WHITE)
readerArea.setBorder(BorderFactory.createEmptyBorder(12, 12, 12, 12))
readerArea.setText("Select a section and topic to start reading.\n\nBixuu's Universe is an offline reference hub. It does not fetch live news, scores, vehicle prices or changing cast lists.")
readPanel.add(new JScrollPane(readerArea), BorderLayout.CENTER)
val split = new JSplitPane(JSplitPane.HORIZONTAL_SPLIT, listPanel, readPanel)
split.setResizeWeight(0.34)
split.setDividerLocation(335)
split.setBorder(null)
split.setOpaque(false)
center.add(split, BorderLayout.CENTER)
val controlBar = new JPanel(new BorderLayout(8, 8))
controlBar.setBackground(PANEL)
controlBar.setBorder(BorderFactory.createEmptyBorder(8, 10, 8, 10))
val leftControls = new JPanel(new java.awt.FlowLayout(java.awt.FlowLayout.LEFT, 7, 0))
leftControls.setOpaque(false)
val prevButton = makeButton("? PREVIOUS")
val nextButton = makeButton("NEXT ?")
val copyButton = makeButton("COPY TEXT")
val saveButton = makeButton("SAVE TXT")
leftControls.add(prevButton); leftControls.add(nextButton); leftControls.add(copyButton); leftControls.add(saveButton)
controlBar.add(leftControls, BorderLayout.WEST)
statusLabel = makeLabel("Ready ? choose a section", 11, GREEN, false)
controlBar.add(statusLabel, BorderLayout.EAST)
center.add(controlBar, BorderLayout.SOUTH)
root.add(navPanel, BorderLayout.WEST)
root.add(center, BorderLayout.CENTER)
sectionList.addListSelectionListener(new ListSelectionListener {
override def valueChanged(e: ListSelectionEvent): Unit = {
if (!e.getValueIsAdjusting && sectionList.getSelectedIndex >= 0) loadSection(sectionList.getSelectedIndex)
}
})
articleList.addListSelectionListener(new ListSelectionListener {
override def valueChanged(e: ListSelectionEvent): Unit = {
if (!e.getValueIsAdjusting && articleList.getSelectedIndex >= 0) displayArticle(articleList.getSelectedIndex)
}
})
searchField.getDocument.addDocumentListener(new DocumentListener {
override def insertUpdate(e: DocumentEvent): Unit = filterArticles()
override def removeUpdate(e: DocumentEvent): Unit = filterArticles()
override def changedUpdate(e: DocumentEvent): Unit = filterArticles()
})
prevButton.addActionListener(new ActionListener {
override def actionPerformed(e: ActionEvent): Unit = {
if (selectedArticleIndex > 0) displayArticle(selectedArticleIndex - 1)
}
})
nextButton.addActionListener(new ActionListener {
override def actionPerformed(e: ActionEvent): Unit = {
if (selectedArticleIndex < visibleArticles.length - 1) displayArticle(selectedArticleIndex + 1)
}
})
copyButton.addActionListener(new ActionListener { override def actionPerformed(e: ActionEvent): Unit = copyCurrent() })
saveButton.addActionListener(new ActionListener { override def actionPerformed(e: ActionEvent): Unit = saveCurrent() })
buildButton.addActionListener(new ActionListener { override def actionPerformed(e: ActionEvent): Unit = buildBusinessIdea() })
frame.setContentPane(root)
frame.setVisible(true)
sectionList.setSelectedIndex(0)
}
def main(args: Array[String]): Unit = {
SwingUtilities.invokeLater(new Runnable {
override def run(): Unit = buildUI()
})
}
}
// Direct startup call for Kojo script-style execution.
BixuuUniverse.main(new Array[String](0))