Python編程基礎與應用 第2版 課件 第6章交互界面設計_第1頁
Python編程基礎與應用 第2版 課件 第6章交互界面設計_第2頁
Python編程基礎與應用 第2版 課件 第6章交互界面設計_第3頁
Python編程基礎與應用 第2版 課件 第6章交互界面設計_第4頁
Python編程基礎與應用 第2版 課件 第6章交互界面設計_第5頁
已閱讀5頁,還剩81頁未讀 繼續免費閱讀

下載本文檔

版權說明:本文檔由用戶提供并上傳,收益歸屬內容提供方,若內容存在侵權,請進行舉報或認領

文檔簡介

1交互界面設計6.1tkinter基礎GUI介紹26.1tkinter基礎GUI介紹36.1tkinter基礎4步法創建tkinter窗口第一步,導入tkinter模塊;第二步,申請frame或Toplevel控件作為容器使用;第三步,創建其他控件;第四步,通過GM(geometrymanager)管理整個控件區域組織。46.1tkinter基礎4步法創建tkinter窗口56.1tkinter基礎4步法創建tkinter窗口66.1tkinter基礎4步法創建tkinter窗口76.1tkinter基礎4步法創建tkinter窗口86.1tkinter基礎4步法創建tkinter窗口96.1tkinter基礎4步法創建tkinter窗口106.1tkinter基礎4步法創建tkinter窗口116.1tkinter基礎4步法創建tkinter窗口126.2tkinter控件的屬性與函數tkinter窗口136.2tkinter控件的屬性與函數tkinter窗口146.2tkinter控件的屬性與函數tkinter窗口156.2tkinter控件的屬性與函數標簽Label166.2tkinter控件的屬性與函數標簽Label176.2tkinter控件的屬性與函數標簽Label186.2tkinter控件的屬性與函數標簽Label196.2tkinter控件的屬性與函數標簽Label206.2tkinter控件的屬性與函數標簽Label216.2tkinter控件的屬性與函數按鈕Button226.2tkinter控件的屬性與函數按鈕Button236.2tkinter控件的屬性與函數按鈕Button246.2tkinter控件的屬性與函數按鈕Button256.2tkinter控件的屬性與函數按鈕Button266.2tkinter控件的屬性與函數文本框控件Entry276.2tkinter控件的屬性與函數文本框控件Entry286.2tkinter控件的屬性與函數文本框控件Entry296.2tkinter控件的屬性與函數復選框Checkbutton306.2tkinter控件的屬性與函數復選框Checkbutton316.2tkinter控件的屬性與函數復選框Checkbutton326.2tkinter控件的屬性與函數復選框Checkbutton336.2tkinter控件的屬性與函數復選框Checkbutton346.2tkinter控件的屬性與函數菜單Menu356.2tkinter控件的屬性與函數菜單Menu366.2tkinter控件的屬性與函數菜單Menu376.2tkinter控件的屬性與函數菜單Menu386.2tkinter控件的屬性與函數菜單Menu396.2tkinter控件的屬性與函數菜單Menu406.2tkinter控件的屬性與函數Menubutton菜單按鈕416.2tkinter控件的屬性與函數Menubutton菜單按鈕426.2tkinter控件的屬性與函數Menubutton菜單按鈕436.2tkinter控件的屬性與函數Listbox列表框446.2tkinter控件的屬性與函數Listbox列表框456.2tkinter控件的屬性與函數Listbox列表框466.2tkinter控件的屬性與函數Listbox列表框476.2tkinter控件的屬性與函數Listbox列表框486.2tkinter控件的屬性與函數Listbox列表框496.2tkinter控件的屬性與函數Scale滑動條506.2tkinter控件的屬性與函數Scale滑動條516.2tkinter控件的屬性與函數Scale滑動條526.2tkinter控件的屬性與函數Scrollbar滾動條536.2tkinter控件的屬性與函數Scrollbar滾動條546.2tkinter控件的屬性與函數Scrollbar滾動條556.2tkinter控件的屬性與函數Scrollbar滾動條566.2tkinter控件的屬性與函數Scale滑動條576.2tkinter控件的屬性與函數Canvas畫布586.2tkinter控件的屬性與函數Canvas畫布596.2tkinter控件的屬性與函數Canvas畫布606.2tkinter控件的屬性與函數Canvas畫布616.2tkinter控件的屬性與函數Text多行文本626.2tkinter控件的屬性與函數Text多行文本636.2tkinter控件的屬性與函數Text多行文本646.2tkinter控件的屬性與函數Text多行文本656.2tkinter控件的屬性與函數Canvas畫布666.2tkinter控件的屬性與函數文本框控件Entry676.2tkinter控件的屬性與函數其他控件686.2tkinter控件的屬性與函數其他控件696.2tkinter控件的屬性與函數其他控件706.3tkinter控件的模塊messagebox模塊716.3tkinter控件的模塊messagebox模塊726.3tkinter控件的模塊simpledialog模塊736.3tkinter控件的模塊simpledialog模塊746.3tkinter控件的模塊simpledialog模塊756.3tkinter控件的模塊simpledialog模塊766.3tkinter控件的模塊tkinter.filedialog模塊776.3tkinter控件的模塊tkinter.filedialog模塊786.3tkinter控件的模塊tkinter.filedialog模塊796.3tkinter控件的模塊tkinter.filedialog模塊806.3tkinter控件的模塊colorchooser模塊816.3tkinter控件的模塊colorchooser模塊826.4綜合案例分析836.4綜合案例分析設計思路第1步:定義按鈕位置,略作修改為四行['7','8','9','/']、['4','5','6','*']、['1','2','3','-']、['0','.','=','+'];第2步:按鈕事件創建功能,包括所有按鈕;第3步:計算公式,采用eval()函數;第4步:創建一個tk窗口;第5步:顯示部分,包括文本框輸入和標簽顯示;第6步:創建所有計算器按鈕;第7步:進入消息循環。846.4綜合案例分析856.4綜合案例分析設計思路:需要兩個文件,即包含Gui類的文件(GUIS.py)和應用文件(GUI應用.py)。Gui類方法包括__init__(self,title='BOM錄入界面')、text_box(self,label)、text_area(self,label)、ch

溫馨提示

  • 1. 本站所有資源如無特殊說明,都需要本地電腦安裝OFFICE2007和PDF閱讀器。圖紙軟件為CAD,CAXA,PROE,UG,SolidWorks等.壓縮文件請下載最新的WinRAR軟件解壓。
  • 2. 本站的文檔不包含任何第三方提供的附件圖紙等,如果需要附件,請聯系上傳者。文件的所有權益歸上傳用戶所有。
  • 3. 本站RAR壓縮包中若帶圖紙,網頁內容里面會有圖紙預覽,若沒有圖紙預覽就沒有圖紙。
  • 4. 未經權益所有人同意不得將文件中的內容挪作商業或盈利用途。
  • 5. 人人文庫網僅提供信息存儲空間,僅對用戶上傳內容的表現方式做保護處理,對用戶上傳分享的文檔內容本身不做任何修改或編輯,并不能對任何下載內容負責。
  • 6. 下載文件中如有侵權或不適當內容,請與我們聯系,我們立即糾正。
  • 7. 本站不保證下載資源的準確性、安全性和完整性, 同時也不承擔用戶因使用這些下載資源對自己和他人造成任何形式的傷害或損失。

評論

0/150

提交評論