# gtk 1.0.0-rc.0

Implements GTK Widgets, themes and titlebar buttons in Flutter. Based on the GNOME HIG




## Installing
```
export PUB_HOSTED_URL=https://pub.mirror.p-hatan.com
flutter pub add 'gtk:1.0.0-rc.0'
```
Published: 2021-10-11T10:38:32.256504Z
Expected archive SHA-256: 8771c670eec719910226a65806c1c75bc763fa929bccbe0f3b8a01d50dbb2b81

Available in cache; verification: upstream_checksum
## Direct dependencies
- flutter: map[sdk:flutter]
- popover: >=0.2.6+2 <1.0.0

## Package README (untrusted upstream documentation)
## GTK ❤️ Flutter

[![Pub.dev](https://img.shields.io/pub/v/gtk.svg)](https://pub.dev/packages/gtk)
[![License](https://img.shields.io/github/license/prateekmedia/gtk-flutter?color=indigo)](LICENSE)
[![Maintainer](https://img.shields.io/badge/Maintainer-prateekmedia-informational)](https://github.com/prateekmedia)

Unofficial implementation of GTK Widgets and libadwaita in Flutter. Based on the GNOME Human Interface Guidelines.

![GTK+Flutter example screenshot](https://user-images.githubusercontent.com/41370460/136773750-eb2a6dcc-bc7b-4054-9207-35fcffd05867.jpg)

### Features

- Libadwaita colors implemented
- Various GTK widgets ported to flutter
- Compatible with [various packages](#additional-information)

### Usage

- Wrap your `MaterialApp` / `CupertinoApp` with `GnomeTheme`
- To get `ThemeData` for `MaterialApp` use `GnomeTheme.of(context).themeData`.
- To get color from theme you can use `GnomeTheme.of(context).[color]` like `GnomeTheme.of(context).tiles`.
- If you want custom titlebar then you can follow the steps for that on [`bitsdojo_window`](https://pub.dev/packages/bitsdojo_window) package.
- Following Widgets are currently ported to flutter:
    - `GtkHeaderBar`
    - `GtkHeaderBarMinimal`
    - `GtkHeaderButton`
    - `GtkPopupMenu`
    - `GtkSidebar`
    - `GtkTwoPane`
    - `GtkViewSwitcher`
    - `GtkViewSwitcherTab`


### Additional information

This package is dependent on 
- [`popover`](https://pub.dev/packages/popover) for GtkPopover.
- [`window_decorations`](https://pub.dev/packages/window_decorations) for Window Decorations (doesn't needed if you use `GtkHeaderBarMinimal`)

Optional packages to use with this package:
- [`adwaita_icons`](https://pub.dev/packages/adwaita_icons) for Adwaita Icons
- [`bitsdojo_window`](https://pub.dev/packages/bitsdojo_window) for better look and feel with custom GtkHeaderBar.bitsdojo
- [`nativeshell`](https://pub.dev/packages/nativeshell) for better look and feel with custom GtkHeaderBar.nativeshell

[Classic API Docs](https://pub.dev/documentation/gtk/latest/)

### License

`LGPL v3 / GNU LESSER GENERAL PUBLIC LICENSE v3`

TLDR;
- You are free to use [this](https://pub.dev/packages/gtk) package in whatever app you want,
- If you improve the package then you should submit your patches / improvements to [this](https://github.com/prateekmedia/gtk-flutter) repository.
## Changelog
## 1.0.0-rc.0

- Use color schemes from libadwaita

## 0.9.8+1

- Remove dead code

## 0.9.8

- Add riverpod example
- Fix selected and unselected color for gtk sidebar
- Fix initial color parsing

## 0.9.5

- Fix instructions on how to use window decoration
- Update README and screenshot

## 0.9.0

- Update gsettings to latest version
- Fix native theme picker by @MalcolmMielle
- Made Window Decorations a seperate package to keep this package lightweight

## 0.8.5

- Use NavigationToolbar instead of Stack to center widget.

## 0.8.0

- Update example
- Add expanded and height property to GtkViewSwitcher

## 0.7.0+1

- Fix Padding of Icons with Gtk header button
- Update `titlebarSpace` and `padding` for `GtkHeaderBar`

## 0.7.0

- Add GtkViewSwitcher from `flutter_gtk` package
- Fix Double tap on header buttons doesn't work.
- Change default padding for header

## 0.6.0

- Remove `adwaita_icons` from dependency of example
- Revamp code for `GtkSidebar`.

## 0.5.5

- Remove `adwaita_icons` from dependency
- Add default values for onClose, onMinimize and onMaximize for GtkHeaderBar.bitsdojo and .nativeshell.
- Add titlebarSpace property to adjust the space b/w titlebar and trailing items.

## 0.5.0+1

- Rename beignDrag to performDrag for nativeshell Gtk Header.

## 0.5.0

- Add onDoubleTap and onHeaderDrag method for GtkHeaderBar
- Add padding and height parameter to GtkHeaderBar
- Add GtkHeaderBar.bitsdojo and GtkHeaderBar.nativeshell to integerate well with these plugins

## 0.4.0+1

- Update Screenshot

## 0.4.0

- Add auto detect gtk theme using GtkColorType.system by @MalcolmMielle
- Update Window Decorations plugin
- Add isActive parameter to Gtk popup button

## 0.2.3

- Change children to body for GtkPopupMenu
- Update Documentation and comments
- Update get Gtk color logic
- Update example by adding bitsdojo_window
- Update Screenshot

## 0.2.0+2

- Fix typo in README
- Add Screenshot in README

## 0.2.0+1

- Update github homepage

## 0.2.0

- Remove `bitsdojo_window` dependency

## 0.1.0+1

- Fix Readme

## 0.1.0

- initial release.







 
