semvec/pypi-packages huggingface dataset:
pyqt-bounding-box 0.0.14
PyQt bounding box for graphic design software
License: MIT


# pyqt-bounding-box
PyQt bounding box for graphic design software

## Requirements
PyQt5 >= 5.8

## Setup
`python -m pip install pyqt-bounding-box`

## Feature
* Cursor shape changes properly for position (horizontal/vertical edge, etc.)
* Being able to resize the box horizontally/vertically/diagonally 
* Being able to move the box with either mouse cursor or arrow keys
* Being able to change the attribute of the box

## Methods Overview
* setLineWidth(self, n: int) - Default width is 3
* setColor(self, color: QColor) - Default color is black
* setStyle(self, style: Qt.PenStyle) - Default style is Qt.DashLine (You can see more about this style in <a href="https://doc.qt.io/qt-6/qt.html#PenStyle-enum">here</a>)
* setWidth(width: int)
* setHeight(height: int)
* setSize(width: int, height: int)

You can use the standard function like `setPen(pen: QPen)` if you know how to use it, Here's the example:

```python
item = BoundingBox()

pen = QPen()
pen.setStyle(Qt.DashLine)
pen.setWidth(3)
pen.setColor(QColor(0, 0, 0))

item.setPen(pen)
```

## Example
Code Sample

```python
from PyQt5.QtWidgets import QWidget, QGraphicsView, QVBoxLayout, QApplication, QGraphicsScene

from pyqt_bounding_box.boundingBox import BoundingBox


class Example(QWidget):
    def __init__(self):
        super().__init__()
        self.__initUi()

    def __initUi(self):
        view = QGraphicsView()
        self.__scene = QGraphicsScene()
        self.__scene.setSceneRect(0, 0, 400, 400)

        item = BoundingBox()
        # item.setLineWidth(8) If you want to change the edge line width, add the code.
        # item.setColor(QColor(255, 255, 255)) If you want to change the color of the line to white, add the code.
        # item.setStyle(Qt.SolidLine) If you want to change the style of line from dashed to solid line, add the code.
        self.__scene.addItem(item)
        view.setScene(self.__scene)

        lay = QVBoxLayout()
        lay.addWidget(view)

        self.setLayout(lay)


if __name__ == "__main__":
    import sys

    app = QApplication(sys.argv)
    example = Example()
    example.show()
    app.exec_()
```

Result

https://user-images.githubusercontent.com/55078043/148708740-cd1f0765-7768-44b6-88bb-770e2d34fe12.mp4

## See Also
* <a href="https://github.com/yjg30737/pyqt-hbounding-box.git">pyqt-hbounding-box</a>
* <a href="https://github.com/yjg30737/pyqt-vbounding-box.git">pyqt-vbounding-box</a>
i3geoweather 1.1.2
Provide temperature information to i3blocks based on geolocated IP address
License: MIT
Keywords: i3 i3wm i3blocks i3blocks-scripts weather-app geolocation weather

i3geoweather
============

This blocklet provides temperature information for the i3blocks status bar
often used in the i3 window manager. It attempts to determine your location
based on your IP address using the `ipinfo.io <http://ipinfo.io>`_
API. Based on the location it retrieves weather information from the free
`openweathermap.org API`__.

.. _openweathermap: http://api.openweathermap.org/

__ openweathermap_

.. image:: docs/i3geoweather.jpg
   :width: 800px
   :target: docs/i3geoweather.jpg

i3geoweather is a pure Python 3 program. No attempt to make it compatible with
Python 2 has been or will be made. It is time to switch!


Installation
------------

The easiest way to install i3geoweather is to use pip::
  
  $ pip install i3geoweather

Depending on your system you may need to call pip3 instead of pip
  

Dependencies
------------

i3geoweather depends on the Python requests_ library. i3geoweather output uses
`FontAwesome <http://fontawesome.io>`_ for its output. You should download the
free FontAwesome zip file and copy fontawesome-webfont.ttf to your ~/.fonts/
directory. 

Usage
-----

i3geoweather runs a daemon process in the background (if started with the -d
option) and periodically updates weather information by writing to
~/.i3geoweather/i3geoweather.txt.

Start i3geoweather from your i3 configuration file::

  exec_always i3geoweather -d

You may need to use the full path to i3geoweather, e.g., for an installation
with pip install --user ...::

  exec_always ~/.local/bin/i3geoweather -d
  
A typical i3blocks.conf entry may look like this::

  [weather]
  interval=repeat
  command=inotifywait -qq -e delete_self ~/.i3geoweather/i3geoweather.txt && cat ~/.i3geoweather/i3geoweather.txt

Command line options:

- -d or --daemon run as background process
- -l or --location force a location by specifying a comma separated
  latitude/longitude pair, e.g., -l "50.0126, 7.996". North and east are
  positive. 
- -r or --restart restart background process
- -s or --stop stop running background process
- -v increase verbosity of logging to ~/.i3geoweather/i3geoweather.log. Can be
  used up to three times. Using -v twice logs informational
  messages. Debugging output is produced when -v is used three times.
     


Author
------

Jörg Dietrich joerg@joergdietrich.com

Contributing
------------

Development takes place on GitHub_. Please report any bugs as an issue in the
GitHub issue tracker.

License
-------

i3geoweather is released under an MIT license. See LICENCE.txt


.. _requests: http://docs.python-requests.org/en/master/
.. _GitHub: https://github.com/joergdietrich/i3geoweather