Skip to content

Instantly share code, notes, and snippets.

@avaris
avaris / test.py
Created May 27, 2012 05:19 — forked from v/test.py
PyQt Network Manager
from PyQt4.QtGui import *
from PyQt4.QtCore import *
from PyQt4.QtWebKit import *
from PyQt4.QtNetwork import *
import sys
class Render(QWebPage):
def __init__(self, url):
self.app = QApplication(sys.argv)
QWebPage.__init__(self)
@avaris
avaris / neighbors.py
Last active December 14, 2015 21:09
Pelican: prev/next article plugin.
from pelican import signals
"""
Neighbor Articles Plugin for Pelican
====================================
Adds ``next_article`` (newer) and ``prev_article`` (older) variables
to the articles context
Usage:

code to test:

mkvirtualenv -p python3.3 pelican-py3-test
pip install -e git+https://github.com/dmdm/smartypants#egg=smartypants
git clone git@github.com:avaris/pelican.git -b 3.3-tests ~/src/pelican-py3-test
cd ~/src/pelican-py3-test/
pip install -r dev_requirements.txt
python setup.py develop
import os
import sys
from PyQt5.QtWidgets import QApplication, QWidget, QToolBox
from PyQt5.QtWidgets import QPushButton, QVBoxLayout, QAction, QMenu
from PyQt5.QtWidgets import QLineEdit, QLabel
class Remove(QWidget):
count = 0