Notice
Recent Posts
Recent Comments
Link
아미(아름다운미소)
python PyQt에서 QCalendarWidget을 사용하여 날짜선택하기 본문
PyQt에서 QCalendarWidget을 사용하여 날짜선택하기
def selectDates(self):
self.dateWindow = QWidget()
self.cal = QCalendarWidget(self)
self.cal.clicked[QtCore.QDate].connect(self.showDate)
self.hbox = QHBoxLayout()
self.hbox.addWidget(self.cal)
self.dateWindow.setLayout(self.hbox)
self.dateWindow.setGeometry(300, 300, 350, 300)
self.dateWindow.setWindowTitle('Calendar')
self.dateWindow.show()
def showDate(self):
print "Date picked: ", self.cal.selectedDate()
'랭귀지 > python' 카테고리의 다른 글
| Python PyQt QDate 형식으로 날짜변경 (0) | 2018.12.20 |
|---|---|
| Python pyqt tableWidget double click event (2) | 2018.12.19 |
| Python PyQt5 messagebox (0) | 2018.12.17 |
| Python PyQt5 QtSql 사용예 (0) | 2018.12.14 |
| Python PyQt5 click action on Qwidget (0) | 2018.12.13 |
Comments