Giter VIP home page Giter VIP logo

qtknobs's Introduction

QtKnobs

QtKnobs is a Qt and QML based Library/Plugin which provides different types of Knobs.

Screenshots:

  • Types

    ScreenShot

  • Percent View

    ScreenShot

  • Minimum & Maximum values

    ScreenShot

  • Various Sizes

    ScreenShot

  • Customize

    ScreenShot

List of properties

  • size
  • value
  • minimumValue
  • maximumValue
  • percent
  • readOnly { true, false }
  • mode { Knob.Normal, Knob.Percent }
  • style { Knob.Pie, Knob.Arc, Knob.Needle }
  • pieType { Knob.Flat, Knob.Curve } (when style = Knob.Pie)
  • needleType { Knob.Point, Knob.Round, Knob.Groove } (when style = Knob.Needle)
  • color (knob color)
  • backgroundColor (back dial color)
  • foregroundColor (front dial color)
  • borderColor
  • textColor
  • meter { true, false } (simple meter)
  • pieMultiColor (some fun)

Requirement

Qt >= 5.3

Building

  • Clone
  • Run qmake && make && make install

The compiled plugin (libqtknobsplugin.so on .nix systems) would be in directory imports/QtKnobs with file qmldir.

Use

If you make install then you need not do anything. But just in case if you want it to be included in your application then:

  • Copy directory imports to your project location
  • To make the engine to search for this module, add the path where the imports directory is using addImportPath.
    For eg. If the directory imports is at location /home/ashish/KnobsTest then,
QQuickView view;
view.engine()->addImportPath("/home/ashish/KnobsTest/imports");
view.show();
  • Additionally, to make QtCreator aware of it (and to get rid of the annoying QML module not found during import) add the path in .pro file,
QML_IMPORT_PATH = /home/ashish/KnobsTest/imports

Examples

  • A simple Knob:

    import QtQuick 2.0
    import QtKnobs 1.0
    Knob {
      value: 25
    }
    

    ScreenShot

    You can find more examples in QtKnobs/examples/main.qml

License

MIT

Contact

Feel free to contact me for any questions at ashishd157 at gmail.com.

qtknobs's People

Contributors

ashish157 avatar machinekoder avatar eyecreate avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.