๋ณธ๋ฌธ ๋ฐ”๋กœ๊ฐ€๊ธฐ
  • Tried. Failed. Logged.
728x90

๐Ÿ‘จ๐Ÿผ‍๐Ÿ’ป๊ฐœ๋ฐœ158

PyQt - ๋””๋ ‰ํ† ๋ฆฌ ๋ฐ ํŒŒ์ผ ๊ฒฝ๋กœ ๋ถˆ๋Ÿฌ์˜ค๊ธฐ(QFileDialog) from PyQt5.QtWidgets import * path = QFileDialog.getExistingDirectory() print(path) file = QFileDialog.getOpenFileName() print(file) ์ถœ์ฒ˜: https://wikidocs.net/5247 1) QFileDialog ์ด๋ฒˆ ์ ˆ์—์„œ๋Š” PyQt๊ฐ€ ์ œ๊ณตํ•˜๋Š” QFileDigalog ํด๋ž˜์Šค์— ๋Œ€ํ•ด ์•Œ์•„๋ณด๊ฒ ์Šต๋‹ˆ๋‹ค. QFileDigalog๋Š” ๊ทธ๋ฆผ 16.43๊ณผ ๊ฐ™์ด ์‚ฌ์šฉ์ž๊ฐ€ ํŒŒ์ผ์ด๋‚˜ ๋””๋ ‰ํ„ฐ๋ฆฌ๋ฅผ ์„ ํƒํ•  ... wikidocs.net 2022. 5. 19.
OpenCV - ์บก์ฑ  ๋ฌธ์ž ๊ฒ€์ถœํ•˜๊ธฐ import cv2 import numpy as numpy import matplotlib.pyplot as plt img = cv2.imread('./characters.PNG') img = cv2.blur(img, (10, 10), anchor=(-1, -1), borderType=cv2.BORDER_DEFAULT) # ๋ธ”๋Ÿฌ์ฒ˜๋ฆฌ(๋–จ์–ด์ง„ ์กฐ๊ฐ์„ ๋ถ™์ด๊ธฐ) img_gray = cv2.cvtColor(img, cv2.COLOR_BGR2GRAY) # ํšŒ์ƒ‰ ์ „ํ™˜ img_gray = 255 - img_gray # ์ด๋ฏธ์ง€ ๋ฐ˜์ „ res, thr = cv2.threshold(img_gray, 90, 255, cv2.THRESH_BINARY) # ์ด์ง„ํ™” cv2.imshow('gray', thr) contours, hie.. 2022. 5. 18.
์ฝ˜์†”์ฐฝ ๋ฐ”๋กœ ๊บผ์ง€์ง€ ์•Š๊ฒŒ ๋ฐฉ์ง€ํ•˜๊ธฐ app.exe :_loop pause goto _loop ์‹คํ–‰.bat 2022. 5. 15.
PyQt - ์Šคํƒ€์ผ์‹œํŠธ ๋ ˆํผ๋Ÿฐ์Šค https://doc.qt.io/archives/qt-4.8/stylesheet-reference.html#list-of-properties Qt Style Sheets Reference | Qt 4.8 Qt Style Sheets Reference Qt Style Sheets support various properties, pseudo-states, and subcontrols that make it possible to customize the look of widgets. The following table lists the Qt widgets that can be customized using style sheets: WidgetHow to St doc.qt.io ์ถœ์ฒ˜: https://forum.. 2022. 5. 9.
ํŒŒ์ด์ฌ - ini ์„ค์ • ํŒŒ์ผ ๋ถˆ๋Ÿฌ์˜ค๊ธฐ import configparser def readConfigure(self): config = configparser.ConfigParser() config.read('./settings.ini', encoding='utf-8') settings = config['settings'] self.uid = settings['uid'] self.upw = settings['upw'] 2022. 5. 8.
ํŒŒ์ด์ฌ - ์Šค๋ ˆ๋“œ ์ƒ๊ด€ ์—†์ด ํ”„๋กœ๊ทธ๋žจ ์™„์ „ ์ข…๋ฃŒ import os os._exit() ์ถœ์ฒ˜: https://stackoverflow.com/questions/905189/why-does-sys-exit-not-exit-when-called-inside-a-thread-in-python Why does sys.exit() not exit when called inside a thread in Python? I am confused as to why the following code snippet would not exit when called in the thread, but would exit when called in the main thread. import sys, time from threading import Thread def testex... 2022. 5. 7.
PyQt - ๊ฐ„๋‹จํ•˜๊ฒŒ ํ† ๊ธ€ ์Šค์œ„์น˜ ๋””์ž์ธํ•˜๊ธฐ QCheckBox::indicator:unchecked { image: url("switch_off.png"); } QCheckBox::indicator:checked { image: url("switch_on.png"); } ์ด๋ฏธ์ง€๋ฅผ ์ด์šฉํ•ด์„œ ํ† ๊ธ€ ๋””์ž์ธ ์ถœ์ฒ˜: https://stackoverflow.com/questions/62363953/how-to-create-toggle-switch-button-in-qt-designer How to create toggle switch button in qt designer? I am trying to create toggle button in qt designer. I refer on internet also but i couldn't find how to .. 2022. 5. 7.
PyQt - designer .ui๋ฅผ .py๋กœ ๋ณ€ํ™˜ํ•˜๊ธฐ pyuic5 -x sub.ui -o sub.py 2022. 5. 7.
PyQt - ์œˆ๋„์šฐ์ฐฝ ํˆฌ๋ช…ํ•˜๊ฒŒ ๋งŒ๋“ค๊ธฐ [์™„์ „ ํˆฌ๋ช…ํ•˜๊ฒŒ ๋งŒ๋“ค๊ธฐ] Form.setWindowFlags(QtCore.Qt.FramelessWindowHint) Form.setAttribute(QtCore.Qt.WA_TranslucentBackground) Form.setStyleSheet("background:transparent;") [๋ถˆํˆฌ๋ช…๋„ ์„ค์ •] Form.setWindowOpacity(0.5) ์ถœ์ฒ˜: https://stackoverflow.com/questions/7667552/qt-widget-with-transparent-background Qt Widget with Transparent Background (I'm using PySide, but I think the answer would be the same/similar for .. 2022. 5. 7.
PyQt - ํŠธ๋ ˆ์ด(Tray) ๋งŒ๋“ค๊ธฐ ๋ฐ ๋ฉ”๋‰ด ์ถ”๊ฐ€ from PyQt5.QtGui import QIcon trayIcon = QSystemTrayIcon(Form) icon = QIcon("icon.png") trayIcon.setIcon(icon) trayIcon.setToolTip('ํŠธ๋ ˆ์ด ์•„์ด์ฝ˜ ์„ค๋ช…') trayIcon.setVisible(True) trayIcon.show() menu = QMenu() exitAction = menu.addAction('Exit') exitAction.triggered.connect(app.quit) trayIcon.setContextMenu(menu) ์ฐธ๊ณ : https://www.pythonguis.com/tutorials/system-tray-mac-menu-bar-applications-pyqt/ System.. 2022. 5. 7.
PyQt - designer ์Šคํƒ€์ผ์‹œํŠธ ์ถ”๊ฐ€ํ•˜๊ธฐ ์›ํ•˜๋Š” ์œ„์ ฏ ์šฐํด๋ฆญํ•˜๊ณ  styleSheet ๋ฐ”๊พธ๊ธฐ ํด๋ฆญ โ€‹์ด๋Ÿฐ์‹์œผ๋กœ border, :hover ๋“ฑ ๋‹ค์–‘ํ•œ ์Šคํƒ€์ผ์‹œํŠธ๋ฅผ ์„ค์ •ํ•  ์ˆ˜ ์žˆ์Œ ๋ฌธ๋ฒ•์€ CSS์™€ ๋™์ผํ•˜๋ฉฐ ๋‹ค๋งŒ ๊ธฐ๋Šฅ์€ ๋” ์ ๋‹ค. ์ฐธ๊ณ : https://blog.naver.com/PostView.naver?blogId=dhksrl0508&logNo=222344023916&parentCategoryNo=&categoryNo=232&viewDate=&isShowPopularPosts=false&from=postView PyQt StyleSheet๋กœ Visual Studio UI๋ฅผ ๋งŒ๋“ค์–ด๋ณด์ž ๋งˆ์ดํฌ๋กœ์†Œํ”„ํŠธ๋Š” UI๋ฅผ ์ •๋ง ์ž˜ ๋งŒ๋“œ๋Š” ๊ฒƒ ๊ฐ™์Šต๋‹ˆ๋‹ค. ํ•™๊ต ๊ณต๋ถ€๋กœ Visual C++ ์‹ค์Šต์„ ์ง„ํ–‰ํ•˜๋Š”๋ฐ, ์šฐ์—ฐ... blog.naver.com 2022. 5. 7.
์…€๋ ˆ๋‹ˆ์›€ - ํฌ๋กฌ ๋ชจ๋ฐ”์ผ ๋ฏธ๋Ÿฌ๋ง(chrome://inspect) ์‚ฌ์šฉ ๋ฐฉ๋ฒ• 1. PC ํฌ๋กฌ์—์„œ "chrome://inspect" ์ฃผ์†Œ๋กœ ์ ‘์† 2. PC์—์„œ adb๋กœ ๋ชจ๋ฐ”์ผ ๋ธŒ๋ฆฟ์ง€ ์—ฐ๊ฒฐ 3. ๋ชจ๋ฐ”์ผ์—์„œ ํฌ๋กฌ ์•ฑ ์‹คํ–‰ ์•ˆ๋“œ๋กœ์ด๋“œ ํฌ๋กฌ์„ ์กฐ์ž‘ํ•  ๋•Œ ์—˜๋ ˆ๋ฉ˜ํŠธ ์š”์†Œ๋ฅผ ๋ถ„์„ํ•  ๋•Œ ์‚ฌ์šฉํ•˜๋ฉด ์ข‹๋‹ค. https://janger.tistory.com/250?category=1254107 ์ฐธ๊ณ : https://jfbta.tistory.com/71 ํฌ๋กฌ ์ธ์ŠคํŽ™ํ„ฐ] chrome inspect, ๋ชจ๋ฐ”์ผ ์›น ๋””๋ฒ„๊น… ํ•˜๋Š” ๋ฐฉ๋ฒ• Chrome Inspect. ํ•œ๊ธ€๋กœ 'ํฌ๋กฌ ์ธ์ŠคํŽ™ํ„ฐ' ๋ผ๊ณ  ํ•˜๋Š”๋ฐ ์‹ค์ œ ๋ชจ๋ฐ”์ผ ๊ธฐ๊ธฐ๋ฅผ ํฌ๋กฌ ๊ฐœ๋ฐœ์žํˆด์—์„œ ๊ทธ๋Œ€๋กœ ๊ตฌํ˜„ํ•ด์„œ ํŽธ๋ฆฌํ•˜๊ฒŒ ๋””๋ฒ„๊น…ํ•  ์ˆ˜ ์žˆ๋Š” ๊ธฐ๋Šฅ์ด๋‹ค. ์‚ฌ์šฉ๋ฐฉ๋ฒ• ์ฒซ์งธ, ๋ชจ๋ฐ”์ผ USB ๋“œ๋ผ์ด๋ฒ„๋ฅผ ์„ค์น˜ํ•œ๋‹ค. jfbta.tistory.com 2022. 4. 9.
728x90