This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <QtWidgets> | |
#include <QThread> | |
#include <QObject> | |
#include <QApplication> | |
#include <QWidget> | |
#include <QVBoxLayout> | |
#include <QTextEdit> | |
class Thread : public QThread |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
# D-Bus Client V2 -- Session Bus | |
import dbus | |
bus = dbus.SessionBus() | |
session = bus.get_object("org.me.test_session", "/org/me/test_session") | |
interface1 = dbus.Interface(session, "org.me.test1") |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
qmake -project | |
# Add option by edit *.pro | |
# QT += core gui widgets | |
qmake | |
make |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /usr/bin/python3 | |
from PyQt5.QtWidgets import QApplication, QMainWindow | |
from PyQt5.QtCore import QCoreApplication, QSettings | |
class Window(QMainWindow): | |
def __init__(self): | |
super(Window, self).__init__() | |
settings = QSettings() | |
self.list = settings.value('list', ['a', 'b', 'c']) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <vector> | |
#include <utility> // std::pair | |
#include <iostream> | |
#include <algorithm> | |
using namespace std; | |
int main(int argc, char const *argv[]) | |
{ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
#include <stdlib.h> | |
#include <unistd.h> | |
#include <errno.h> | |
#include <string.h> | |
#include <sys/types.h> | |
#include <sys/socket.h> | |
#include <netinet/in.h> | |
#include <arpa/inet.h> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import os | |
import uuid | |
import threading | |
import logging | |
import subprocess | |
class LogPipe(threading.Thread): | |
def __init__(self, logfile=None, level=logging.INFO): | |
"""Setup the object with a logger and a loglevel and start the thread |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from PyQt5.QtWidgets import QApplication, QMainWindow, QLabel, QVBoxLayout, QPushButton, QWidget | |
from PyQt5.QtCore import QObject, QRunnable, QThreadPool,pyqtSlot, pyqtSignal | |
import time | |
import traceback, sys | |
class WorkerSignals(QObject): | |
''' | |
Defines the signals available from a running worker thread. | |
Supported signals are: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
from PyQt5.QtCore import QDateTime, Qt, QTimer | |
from PyQt5.QtWidgets import (QApplication, QCheckBox, QComboBox, QDateTimeEdit, | |
QDial, QDialog, QGridLayout, QGroupBox, QHBoxLayout, QLabel, QLineEdit, | |
QProgressBar, QPushButton, QRadioButton, QScrollBar, QSizePolicy, | |
QSlider, QSpinBox, QStyleFactory, QTableWidget, QTabWidget, QTextEdit, | |
QVBoxLayout, QWidget) | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Ignore generated files | |
/*.deb | |
/*.dsc | |
/*.changes | |
# Only care about debian/ directory | |
/*/* | |
!/*/debian | |
# Ignore files generated during build |