GithubHelp home page GithubHelp logo

olivierldff / qaterialgallery Goto Github PK

View Code? Open in Web Editor NEW
99.0 13.0 19.0 8.48 MB

🖼️ Qaterial Library Showcase.

Home Page: https://olivierldff.github.io/QaterialGallery/

License: MIT License

CMake 9.66% QML 86.52% C++ 2.38% HTML 1.44%
library-qaterial qt qml qtquick qtcontrols material material-components

qaterialgallery's Introduction

Qaterial Gallery

Configuration Status
Windows Installer 👷 Windows CI
Linux AppImage 👷 AppImage CI
MacOs Dmg 👷 MacOs CI
Android Apk 👷 Android CI
iOs Ipa 👷 iOs CI
Wasm 👷 Wasm CI

downloadappstore

QaterialGallery is a showcase application and contains example for the library Qaterial . It is still under development. This library is hard fork of previous library QQuickMaterialHelper.

This project also showcase multiplatform deployment with Qt.

Components

Main Page

screen3

Menu Bar

screen4

Buttons

screen5

Icons

screen6

Floating Action Button

screen7

Controls Buttons

screen8

Typography

screen9

Text Field

screen10

Tab

screen11

Cards

screen12

Frame

screen13

Group Box

screen14

Snackbars

screen15

Dialogs

screen16

DOC TODO

Build

QaterialGallery is a cross platform application that can be build natively or cross compiled. Qt precompiled binary are required and can be download from the official website. Then simply use the qt manager to install the toolchain that you need. Minimum Qt version is 5.12.

Windows

To build the application for windows it is required to already be on a windows machine. It is recommended to export the path as global variable.

export QT_WIN_VERSION=5.12.0
export QT_DIR_MINGW32=C:/Qt/$QT_WIN_VERSION/mingw53_32
export QT_DIR_MINGW64=C:/Qt/$QT_WIN_VERSION/mingw53_64
export QT_DIR_MSVC32=C:/Qt/$QT_WIN_VERSION1/msvc2017_32
export QT_DIR_MSVC64=C:/Qt/$QT_WIN_VERSION/msvc2017_64

Then simply clone the repository and create an in source build folder.

git clone https://github.com/OlivierLdff/QaterialGallery
cd QaterialGallery && mkdir build && cd build

MinGw 32 bits - Make

cmake -DCMAKE_PREFIX_PATH=$QT_DIR_MINGW32 \
-G "Unix Makefiles" -DCMAKE_BUILD_TYPE=$QT_BUILD_TYPE path/to/CMakeLists/

MinGw 64 bits - Ninja

cmake -DCMAKE_PREFIX_PATH=$QT_DIR_MINGW64 \
-G "Ninja" -DCMAKE_BUILD_TYPE=$QT_BUILD_TYPE path/to/CMakeLists/

Msvc 32 bits (Default)

cmake -DCMAKE_PREFIX_PATH=$QT_DIR_MSVC32 \
-G "Visual Studio 15 2017" path/to/CMakeLists/

Msvc 64 bits

cmake -DCMAKE_PREFIX_PATH=$QT_DIR_MSVC64 \
-G "Visual Studio 15 2017 Win64" path/to/CMakeLists/

Linux

TODO

Mac

TODO

Android

Requirement

Environment variable

You need to the following environment variable to be set.

  • ANDROID_SDK : Path to the Android Sdk.
  • ANDROID_NDK : Path to the Android Ndk
  • JAVA_HOME : Path to the Java (mainly to use the jarsigner utility).

To build the application for windows it is required to already be on a windows machine. It is recommended to export the path as global variable.

export QT_ANDROID_VERSION=5.12.0
## On Windows
export QT_DIR_ARMV7A=C:/Qt/$QT_ANDROID_VERSION/android_armv7
export QT_DIR_ARM64V8A=C:/Qt/$QT_WIN_VERSION1/android_arm64_v8a
export QT_DIR_X86=C:/Qt/$QT_WIN_VERSION/android_x86
## On UNIX system
export QT_DIR_ARMV7A=Path/To/Qt/$QT_ANDROID_VERSION/android_armv7
export QT_DIR_ARM64V8A=Path/To/Qt/$QT_WIN_VERSION1/android_arm64_v8a
export QT_DIR_X86=Path/To/Qt/$QT_WIN_VERSION/android_x86
## On macOs
export QT_USER_ID=$(id -un)
export QT_DIR_ARMV7A=/Users/$QT_USER_ID/Qt/$QT_ANDROID_VERSION/android_armv7
export QT_DIR_ARM64V8A=/Users/$QT_USER_ID/Qt/$QT_WIN_VERSION1/android_arm64_v8a
export QT_DIR_X86=/Users/$QT_USER_ID/Qt/$QT_WIN_VERSION/android_x86

CMAKE_BUILD_TYPE can be set to multiple values. Debug | Release | MinSizeRel | RelWithDebInfo.

Tip for windows: If you don't have make installed you can use the one in the ndk:

-DCMAKE_MAKE_PROGRAM="$ANDROID_NDK/prebuilt/windows-x86_64/bin/make.exe"

Arm v7a

mkdir build-android-armeabi-v7a && cd build-android-armeabi-v7a
cmake -DQT_DIR=$QT_DIR_ARMV7A -G "Unix Makefiles" \
-DCMAKE_TOOLCHAIN_FILE=$ANDROID_NDK/build/cmake/android.toolchain.cmake \
-DCMAKE_BUILD_TYPE=Release \
-DANDROID_ABI=armeabi-v7a \
-DANDROID_NATIVE_API_LEVEL=27 \
-DANDROID_STL=c++_shared \
-DANDROID_TOOLCHAIN=clang \
-DQATERIALGALLERY_BUILD_SHARED=ON \
-DQATERIALGALLERY_ANDROID_KEYSTORE=Path/To/Keystore \
-DQATERIALGALLERY_ANDROID_KEYSTORE_ALIAS=KeystoreAlias \
-DQATERIALGALLERY_ANDROID_KEYSTORE_PASSWORD=xxxx \
..
make -j8

The resulted apk will be in QaterialGallery-armeabi-v7a/build/outputs/apk/release/.

Arm64 v8a

mkdir build-android-arm64-v8a && cd build-android-arm64-v8a
cmake -DQT_DIR=$QT_DIR_ARM64V8A -G "Unix Makefiles" \
-DCMAKE_TOOLCHAIN_FILE=$ANDROID_NDK/build/cmake/android.toolchain.cmake \
-DCMAKE_BUILD_TYPE=Release \
-DANDROID_ABI=arm64-v8a \
-DANDROID_NATIVE_API_LEVEL=27 \
-DANDROID_STL=c++_shared \
-DANDROID_TOOLCHAIN=clang \
-DQATERIALGALLERY_ANDROID_KEYSTORE=Path/To/Keystore \
-DQATERIALGALLERY_ANDROID_KEYSTORE_ALIAS=KeystoreAlias \
-DQATERIALGALLERY_ANDROID_KEYSTORE_PASSWORD=xxxx \
..
make -j8

The resulted apk will be in QaterialGallery-arm64-v8a/build/outputs/apk/release/.

x86

mkdir build-android-x86 && cd build-android-x86
cmake -DQT_DIR=$QT_DIR_X86 -G "Unix Makefiles" \
-DCMAKE_TOOLCHAIN_FILE=$ANDROID_NDK/build/cmake/android.toolchain.cmake \
-DCMAKE_BUILD_TYPE=Release \
-DANDROID_ABI=x86 \
-DANDROID_NATIVE_API_LEVEL=27 \
-DANDROID_STL=c++_shared \
-DANDROID_TOOLCHAIN=clang \
-DQATERIALGALLERY_BUILD_SHARED=ON \
-DQATERIALGALLERY_ANDROID_KEYSTORE=Path/To/Keystore \
-DQATERIALGALLERY_ANDROID_KEYSTORE_ALIAS=KeystoreAlias \
-DQATERIALGALLERY_ANDROID_KEYSTORE_PASSWORD=xxxx \
..
make -j8

The resulted apk will be in QaterialGallery-x86/build/outputs/apk/release/.

Ios

Prerequisite:

Prepare Environment:

If you installed official Qt binary, Qt Sdk binary is located in:

export QT_USER_ID=$(id -un)
export QT_IOS_VERSION=5.15.1
export QT_IOS_DIR=/Users/$QT_USER_ID/Qt/$QT_IOS_VERSION/ios

Run CMake:

Then simply run CMake with this toolchain. Read the toolchain README for more information.

cmake -DCMAKE_PREFIX_PATH=$QT_IOS_DIR \
-DDEPLOYMENT_TARGET=12.0 \
-DCMAKE_TOOLCHAIN_FILE=/path/to/ios.toolchain.cmake \
-DPLATFORM=OS64COMBINED \
-DENABLE_BITCODE=FALSE \
-DTEAM_ID=AAAAAAAA \
-G "XCode" \
path/to/Projet/

Build:

Then you can simply build your app:

cmake --build . --config Release

or launch the generated XCode project.

Ipa will be located in QaterialGalleryIpa/Qaterial.ipa.

Configuration

Input

Note: Exe, Shared and Static can't be ON at the same time.

  • QATERIALGALLERY_BUILD_SHARED : Build as a shared library [ON OFF]. Default: OFF.
  • QATERIALGALLERY_BUILD_STATIC : Build as a static library [ON OFF]. Default: OFF.
  • QATERIALGALLERY_BUILD_EXE : Build as an executable [ON OFF]. Default: ON.
  • QATERIALGALLERY_PROJECT : Name of the project. Default: QaterialGallery.
  • QATERIALGALLERY_TARGET : Name of the project. Default: QaterialGallery.

Dependencies

Output

  • QATERIALGALLERY_TARGET : Output target to link to. Default: QaterialGallery

Versions

To create a new release:

  • Update in CMakelist.txt variables QATERIALGALLERY_VERSION_MAJOR, QATERIALGALLERY_VERSION_MINOR, QATERIALGALLERY_VERSION_PATCH.
  • Increment in platform/PostBuildPlatform.cmake the parameter VERSION_CODE in the android apk macro

Authors

qaterialgallery's People

Contributors

cedricleon avatar colombel-vincent avatar olivierldff avatar pcales avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

qaterialgallery's Issues

compile errror.

xcode12.4 maxcos10.15.7

error: unable to spawn process '/bin/sh' (Argument list too long) (in target 'QaterialIcons' from project 'QaterialGallery')

qmake project

Sa seras bien, si on pouvais l'utiliser avec qmake, étant nouveau avec cmake je galère comme un fou, sa marche mais,
mais je peux pas l'utiliser dans mes projects précédent trop de modification a faire

TreeView

First let me say this project is awesome and real stunning :)

Have you considered to introduce a TreeView component?

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.