Nyob rau hauv lub pob twg Java Swing API muaj nyob?
Nyob rau hauv lub pob twg Java Swing API muaj nyob?

Video: Nyob rau hauv lub pob twg Java Swing API muaj nyob?

Video: Nyob rau hauv lub pob twg Java Swing API muaj nyob?
Video: Lub Neej Zoo Li Dej Ntws - Paj Muas Vwj ( Tus Tswv Yexus Ib leeg ) 2024, Kaum ib hlis
Anonim

Keeb kwm muab faib raws li ib tug nyias muaj nyias lub tsev qiv ntawv, Swing tau suav nrog ua ib feem ntawm Java Standard Edition txij li thaum tso tawm 1.2. Cov Viav cov chav kawm thiab cov khoom muaj nyob hauv javax ua . viav vias pob hierarchy.

Hais txog qhov no, Swing pob hauv Java yog dab tsi?

Java Swing tutorial yog ib feem ntawm Java Cov Chav Kawm Foundation (JFC) uas yog siv los tsim cov ntawv thov hauv qhov rais. viav vias pob muab cov chav kawm rau java swb API xws li JButton, JTextField, JTextArea, JRadioButton, JCheckbox, JMenu, JColorChooser thiab lwm yam.

Qhov thib ob, vim li cas peb thiaj siv Swing hauv Java? Swing yog ib txheej ntawm cov program tivthaiv s rau Java programmers uas muab lub peev xwm los tsim graphical user interface (GUI) cov khoom, xws li cov nyees khawm thiab scroll bars, kos lub thawv, cov ntawv lo, cov ntawv nyeem uas tsis muaj kev ywj pheej ntawm lub qhov rais rau kev ua haujlwm tshwj xeeb.

Tsis tas li ntawd, puas tseem siv Java Swing?

Swing yog tseem siv tau hnyav, thiab yuav txuas ntxiv mus ntev - tom qab tag nrho, nws tsuas yog xaiv rau Java rau ib lub sij hawm looong. JavaFX, txawm li cas los xij, yog qhov zoo nkauj tshiab, thiab muaj txiaj ntsig zoo heev rau kev kawm.

Dab tsi yog chav kawm hauv paus rau tag nrho Swing Cheebtsam hauv Java siab heev?

Cov chav kawm JComponent yog base class rau tag nrho Swing Cheebtsam tshwj tsis yog cov thawv ntim saum toj kawg nkaus. Yuav siv a tiv thaiv uas tau txais los ntawm JComponent, koj yuav tsum tso qhov tiv thaiv nyob rau hauv ib qho kev txwv hierarchy uas nws cov hauv paus yog ib qho saum toj kawg nkaus SWING thawv.

Pom zoo: