freepeople性欧美熟妇, 色戒完整版无删减158分钟hd, 无码精品国产vα在线观看DVD, 丰满少妇伦精品无码专区在线观看,艾栗栗与纹身男宾馆3p50分钟,国产AV片在线观看,黑人与美女高潮,18岁女RAPPERDISSSUBS,国产手机在机看影片

正文內(nèi)容

面向?qū)ο蟪绦虻脑O(shè)計—文本編輯器的設(shè)計與實現(xiàn)-在線瀏覽

2024-08-17 16:19本頁面
  

【正文】 nListener() { public void actionPerformed( ActionEvent event ) { (*.java)。 (另存為)。 if (() != null) { File file = new File(())。 //,之后可以用PrintWriter pw = new PrintWriter(file)。 //這一部分用于把textArea1中的內(nèi)容打印到pw指定的文件file中去,file圍在對話框中選定的文件 ()。 } catch (FileNotFoundException ex) {()。} }})。 //加分隔線 // 設(shè)置退出菜單項 JMenuItem exitItem = new JMenuItem( 退出(X) )。x39。 ( exitItem )。 } } )。/**/ //創(chuàng)建編輯菜單及其菜單項 JMenu editMenu = new JMenu( 編輯(E) )。E39。 //剪切菜單選項 JMenuItem cutItem = new JMenuItem( 剪切(T) )。T39。 ( cutItem )。//取得選定的文本 int start = ()。//選定的文本的結(jié)束位置 (, start, end)。 這里指定替換文本為空,即為剪切了文本*/ } } )。 ( 39。 )。 ( new ActionListener(){ public void actionPerformed( ActionEvent event ){ selectText = ()。 //粘貼的實現(xiàn) JMenuItem pasteItem = new JMenuItem( 粘貼(P) )。P39。 ( pasteItem )。//獲得鼠標當(dāng)前位置 ( selectText,position )。 ()。 ( 39。 )。 ( new ActionListener(){ public void actionPerformed( ActionEvent event ){ JPanel swapPanel=new JPanel()。 JTextField inputText=new JTextField(10)。 JTextField changetoText=new JTextField(10)。 (inputText)。 (changetoText)。 String text=()。//獲得替換后的內(nèi)容 (changeText)。 //全部替換的實現(xiàn) JMenuItem aswapItem = new JMenuItem( 全部替換(Q)) )。Q39。 ( aswapItem )。 JLabel lookupLabel=new JLabel(要替換的內(nèi)容)。 JLabel swapLabel=new JLabel(替換為:)。 (lookupLabel)。 (swapLabel)。 (null,swapPanel)。//獲得整個文本內(nèi)容 String changeText=((),())。 } } )。//加分隔線 //插入子菜單 JMenuItem insertItem=new JMenuItem(插入文本(K))。K39。 (insertItem)。 JLabel insertLabel=new JLabel(要插入的內(nèi)容)。 (insertLabel)。 (null,insertPanel)。//取得當(dāng)前的光標位置 ((),fromIndex)。 //刪除子菜單 JMenuItem RemoveItem=new JMenuItem(刪除(G))。G39。 (RemoveItem)。 int end=()。 } })。 ( editMenu )。 ( 39。 )。 ( 39。 )。 ( new ActionListener(){ boolean var = false。 else var=true。 } } )。 JMenu colorMenu = new JMenu( 顏色(C) )。C39。 colorItems = new JRadioButtonMenuItem[ ]。 ItemHandler itemHandler = new ItemHandler()。 count 。 ( colorItems[ count ] )。 colorItems[ count ].addActionListener( itemHandler )。 // 將顏色菜單項菜單加入菜單 ( colorMenu )。 //加分隔線 // 字體菜單項 JMenu fontMenu = new JMenu( 字體(n) )。n39。 fonts = new JRadioButtonMenuItem[ ]。 // 創(chuàng)建字體按鈕監(jiān)聽器 for ( int count = 0。 count++ ) { fonts[ count ] = new JRadioButtonMenuItem( fontNames[ count ] )。 ( fonts[ count ] )。 } // 默認字體 fonts[ 0 ].setSelected( true )。 // 設(shè)置風(fēng)格菜單 styleItems = new JCheckBoxMenuItem[ ]。 count 。 ( styleItems[ count ] )。 styleItems[ count ].addItemListener( styleHandler )。 ( formatMenu )。 ( 39。 )。 ( 39。 )。 ( new ActionListener() { public void actionPerformed( ActionEvent event ) {JPanel swapPanel=new JPanel()。 JTextField inputText=new JTextField(20)。 (inputText)。 String text=()。//取得當(dāng)前的光標位置 int lastfromIndex=((),fromIndex)。 (lastfromIndex+().length())。 //添加向后查找菜單項 JMenuIte
點擊復(fù)制文檔內(nèi)容
畢業(yè)設(shè)計相關(guān)推薦
文庫吧 www.dybbs8.com
備案圖鄂ICP備17016276號-1