Skip to content

Commit

Permalink
Resolve merge conflict
Browse files Browse the repository at this point in the history
  • Loading branch information
HeaTTheatR committed Jan 17, 2024
2 parents 3bf651d + 3acfc6e commit 6623c8d
Show file tree
Hide file tree
Showing 281 changed files with 24,224 additions and 32,242 deletions.
8 changes: 4 additions & 4 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,19 +7,19 @@ repos:

# Format Python
- repo: https://github.com/psf/black
rev: 22.3.0
rev: 23.12.1
hooks:
- id: black

# Sort imports
- repo: https://github.com/PyCQA/isort
rev: 5.10.1
rev: 5.13.2
hooks:
- id: isort
additional_dependencies: ["toml"]

# Lint Python
- repo: https://gitlab.com/PyCQA/flake8
rev: 4.0.1
- repo: https://github.com/PyCQA/flake8
rev: 7.0.0
hooks:
- id: flake8
15 changes: 2 additions & 13 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -1,18 +1,7 @@
MIT License

Copyright (c) 2022 Andrés Rodríguez and other contributors - KivyMD library up to version 0.1.2
Copyright (c) 2022 KivyMD Team and other contributors - KivyMD library version 0.1.3 and higher

Other libraries used in the project:

Copyright (c) 2010-2022 Kivy Team and other contributors
Copyright (c) 2022 Brian Knapp - Androidoast library
Copyright (c) 2022 LogicalDash - stiffscroll library
Copyright (c) 2022 Kivy Garden - tabs module
Copyright (c) 2022 Nattōsai Mitō - asynckivy module
Copyright (c) 2022 tshirtman - magic_behavior module
Copyright (c) 2022 shashi278 - taptargetview module
Copyright (c) 2022 Benedikt Zwölfer - fitimage module
Copyright (c) 2024 Andrés Rodríguez and other contributors - KivyMD library up to version 0.1.2
Copyright (c) 2024 KivyMD Team and other contributors - KivyMD library version 0.1.3 and higher

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
28 changes: 10 additions & 18 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,10 +48,11 @@ pip install kivymd==2.0.0

### Dependencies:

- [Kivy](https://github.com/kivy/kivy) >= 2.2.0 ([Installation](https://kivy.org/doc/stable/gettingstarted/installation.html))
- [Kivy](https://github.com/kivy/kivy) >= 2.3.0 ([Installation](https://kivy.org/doc/stable/gettingstarted/installation.html))
- [Python 3.7+](https://www.python.org/)
- [Pillow](https://github.com/python-pillow/Pillow/)
- [MaterialColor](https://github.com/T-Dynamos/materialyoucolor-pyhton)
- [asynckivy](https://github.com/asyncgui/asynckivy)

### How to install

Expand Down Expand Up @@ -81,25 +82,16 @@ pip install .
use a shallow clone (`git clone https://github.com/kivymd/KivyMD.git --depth 1`)
to save time. If you need full commit history, then remove `--depth 1`.

### How to fix a shader bug on an android device

Use `Kivy` from master branch or `Kivy` >= `2.2.0` and `KivyMD` (from master branch):

```bash
pip install https://github.com/kivy/kivy/archive/master.zip
pip install https://github.com/kivymd/KivyMD/archive/master.zip
```

And use with `Buildozer`:

```ini
requirements = kivy==master, https://github.com/kivymd/KivyMD/archive/master.zip
```

### How to use with [Buildozer](https://github.com/kivy/buildozer)

```ini
requirements = kivy==2.1.0, kivymd==1.1.1
requirements = python3,
kivy,
https://github.com/kivymd/KivyMD/archive/master.zip,
materialyoucolor,
exceptiongroup,
asyncgui,
asynckivy
```

This will download latest release version of KivyMD from [PyPI](https://pypi.org/project/kivymd).
Expand All @@ -108,7 +100,7 @@ If you want to use development version from [master](https://github.com/kivymd/K
branch, you should specify link to zip archive:

```ini
requirements = kivy==2.1.0, https://github.com/kivymd/KivyMD/archive/master.zip
requirements = kivy, https://github.com/kivymd/KivyMD/archive/master.zip
```

Do not forget to run `buildozer android clean` or remove `.buildozer` directory
Expand Down
2 changes: 1 addition & 1 deletion docs/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

# You can set these variables from the command line, and also
# from the environment for the first two.
SPHINXOPTS ?=
SPHINXOPTS ?= -T
SPHINXBUILD ?= sphinx-build
SOURCEDIR = sources
BUILDDIR = build
Expand Down
23 changes: 20 additions & 3 deletions docs/sources/_extensions/autoapi_kivymd.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,17 +16,20 @@
import autoapi
import sphinx
import unidecode
from autoapi.directives import NestedParse
from autoapi.extension import LOGGER
from autoapi.extension import setup as autoapi_setup
from autoapi.mappers.python.mapper import PythonSphinxMapper
from autoapi.mappers.python.objects import PythonPythonMapper
from docutils import nodes
from sphinx.util.console import bold, darkgreen
from sphinx.util.nodes import nested_parse_with_titles
from sphinx.util.osutil import ensuredir


def PythonPythonMapper_include_dir(self: PythonPythonMapper, root):
if os.path.isabs(root):
parts = [self.app.confdir]
parts = [str(self.app.confdir)]
else:
parts = [""] # Config root folder
parts.extend(self.pathname.split(os.path.sep))
Expand All @@ -50,11 +53,11 @@ def PythonPythonMapper_pathname(self: PythonPythonMapper):
def PythonSphinxMapper_output_rst(
self: PythonSphinxMapper, root, source_suffix
):
for _, obj in sphinx.util.status_iterator(
for _, obj in sphinx.util.display.status_iterator(
self.objects.items(),
bold("[AutoAPI] ") + "Rendering Data... ",
length=len(self.objects),
verbosity="INFO",
verbosity=1,
stringify_func=(lambda x: x[0]),
):
rst = obj.render(
Expand Down Expand Up @@ -128,7 +131,21 @@ def extension_build_finished(app, exception):
break


def patched_nested_parse_run(self):
node = nodes.container()
node.document = self.state.document
nested_parse_with_titles(self.state, self.content, node)
try:
title_node = node[0][0]
if isinstance(title_node, nodes.title):
title_node.children.pop(0)
except IndexError:
pass
return node.children


def setup(app):
NestedParse.run = patched_nested_parse_run
PythonPythonMapper.pathname = property(PythonPythonMapper_pathname)
PythonPythonMapper.include_dir = PythonPythonMapper_include_dir
PythonSphinxMapper.output_rst = PythonSphinxMapper_output_rst
Expand Down
14 changes: 7 additions & 7 deletions docs/sources/changelog/1.0.0.rst
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
* Bug fixes and other minor improvements.
* Added `ImageLeftWidgetWithoutTouch`, `ImageRightWidgetWithoutTouch`, `IconRightWidgetWithoutTouch`, `IconLeftWidgetWithoutTouch` classes to *kivymd/uix/list.py* module;
* Added `MDStepper <https://kivymd.readthedocs.io/en/latest/components/stepper/>`_ component;
* Added a feature, `show_disks <https://kivymd.readthedocs.io/en/latest/components/filemanager/#kivymd.uix.filemanager.filemanager.MDFileManager.show_disks>`_ to the `MDFileManager <https://kivymd.readthedocs.io/en/latest/components/filemanager/#module-kivymd.uix.filemanager.filemanager>`_ class, that allows you to display the disks and folders contained in them;
* Added a feature, `show_disks <https://kivymd.readthedocs.io/en/latest/components/filemanager/#kivymd.uix.filemanager.filemanager.MDFileManager.show_disks>`_ `to the MDFileManager <https://kivymd.readthedocs.io/en/latest/components/filemanager/#module-kivymd.uix.filemanager.filemanager>`_ class, that allows you to display the disks and folders contained in them;
* Added `animation_tooltip_dismiss <https://kivymd.readthedocs.io/en/latest/components/tooltip/#kivymd.uix.tooltip.tooltip.MDTooltip.animation_tooltip_dismiss>`_ function and `on_dismiss <https://kivymd.readthedocs.io/en/latest/components/tooltip/#kivymd.uix.tooltip.tooltip.MDTooltip.on_dismiss>`_ event to `MDTooltip <https://kivymd.readthedocs.io/en/latest/components/tooltip/#module-kivymd.uix.tooltip.tooltip>`_ class;
* Added `MDColorPicker <https://kivymd.readthedocs.io/en/latest/components/colorpicker/#module-kivymd.uix.pickers.colorpicker.colorpicker>`_ component;
* Added new `transition <https://github.com/kivymd/KivyMD/tree/master/kivymd/uix/transition>`_ package - a set of classes for implementing transitions between application screens;
Expand All @@ -21,11 +21,11 @@
* Added `Templates package <https://kivymd.readthedocs.io/en/latest/templates/>`_ - base classes for controlling the scale, rotation of the widget, etc.;
* Added `kivymd/tools/patterns <https://kivymd.readthedocs.io/en/latest/api/kivymd/tools/patterns/create_project/>`_ package - scripts for creating projects with design patterns;
* `FitImage` widget move from `kivymd.utils` to `kivymd.uix.fitimage`;
* Added `background_color_header <https://kivymd.readthedocs.io/en/latest/components/datatables/#kivymd.uix.datatables.datatables.MDDataTable.background_color_header>`_, `background_color_cell <https://kivymd.readthedocs.io/en/latest/components/datatables/#kivymd.uix.datatables.datatables.MDDataTable.background_color_cell>`_, `background_color_selected_cell <https://kivymd.readthedocs.io/en/latest/components/datatables/#kivymd.uix.datatables.datatables.MDDataTable.background_color_selected_cell>`_, added methods for adding/removing rows to a common table to `MDDataTable <https://kivymd.readthedocs.io/en/latest/components/datatables/#module-kivymd.uix.datatables.datatables>`_ widget;
* Added method for `update rows <https://kivymd.readthedocs.io/en/latest/components/datatables/#kivymd.uix.datatables.datatables.MDDataTable.update_row>`_ to `MDDataTable <https://kivymd.readthedocs.io/en/latest/components/datatables/#module-kivymd.uix.datatables.datatables>`_ class;
* Added `background_color_header <https://kivymd.readthedocs.io/en/latest/components/datatables/#kivymd.uix.datatables.datatables.MDDataTable.background_color_header>`_, `background_color_cell <https://kivymd.readthedocs.io/en/latest/components/datatables/#kivymd.uix.datatables.datatables.MDDataTable.background_color_cell>`_, `background_color_selected_cell <https://kivymd.readthedocs.io/en/latest/components/datatables/#kivymd.uix.datatables.datatables.MDDataTable.background_color_selected_cell>`_, added methods for adding/removing rows to a `common table to MDDataTable <https://kivymd.readthedocs.io/en/latest/components/datatables/#module-kivymd.uix.datatables.datatables>`_ widget;
* Added method for `update rows <https://kivymd.readthedocs.io/en/latest/components/datatables/#kivymd.uix.datatables.datatables.MDDataTable.update_row>`_ `to MDDataTable <https://kivymd.readthedocs.io/en/latest/components/datatables/#module-kivymd.uix.datatables.datatables>`_ class;
* Delete `kivymd/utils/hot_reload_viewer.py`;
* Added `kivymd/tools/hotreload <https://kivymd.readthedocs.io/en/latest/api/kivymd/tools/hotreload/app/>`_ package;
* Added `top` value to `position <https://kivymd.readthedocs.io/en/latest/components/menu/#kivymd.uix.menu.menu.MDDropdownMenu.position>`_ parameter of `MDDropdownMenu <https://kivymd.readthedocs.io/en/latest/components/menu/#module-kivymd.uix.menu.menu>`_ class;
* Added `top` value to `position <https://kivymd.readthedocs.io/en/latest/components/menu/#kivymd.uix.menu.menu.MDDropdownMenu.position>`_ `parameter of MDDropdownMenu <https://kivymd.readthedocs.io/en/latest/components/menu/#module-kivymd.uix.menu.menu>`_ class;
* Added `get_current_tab <https://kivymd.readthedocs.io/en/latest/components/tabs/#kivymd.uix.tab.tab.MDTabs.get_current_tab>`_ method to `MDTabs <https://kivymd.readthedocs.io/en/latest/components/tabs/>`_ class;
* Added the feature to automatically create a virtual environment when creating a project using the `kivymd.tools.patterns.create_project <https://kivymd.readthedocs.io/en/latest/api/kivymd/tools/patterns/create_project/>`_ tool;
* Added the feature to use the `left_icon <https://kivymd.readthedocs.io/en/latest/components/textfield/#kivymd.uix.textfield.textfield.MDTextField.icon_left>`_ for `MDTextField <https://kivymd.readthedocs.io/en/latest/components/textfield/#kivymd.uix.textfield.textfield.MDTextField>`_ text fields;
Expand All @@ -37,13 +37,13 @@
* Added the feature to use a radius for the `BaseListItem` class;
* `MDFloatingActionButton <https://kivymd.readthedocs.io/en/latest/components/button/#mdfloatingactionbutton>`_ class `configured according to M3 <https://kivymd.readthedocs.io/en/latest/components/button/#material-design-style-3>`_ style;
* Ripple animation for round buttons customized to material design standards;
* `Fix <https://github.com/kivymd/KivyMD/pull/1141>`_ `Warning, too much iteration done before the next frame` for button classes;
* `Fix Warning, too much iteration done before the next frame <https://github.com/kivymd/KivyMD/pull/1141>`_ for button classes;
* Added `FadingEdgeEffect class <https://kivymd.readthedocs.io/en/latest/effects/fadingedgeeffect/>`_
* Added `MDSliverAppBar <https://kivymd.readthedocs.io/en/latest/components/sliverappbar/#module-kivymd.uix.sliverappbar.sliverappbar>`_ widget;
* Added the feature to use `custom icons <https://kivymd.readthedocs.io/en/latest/components/bottomnavigation/#use-custom-icon>`_ and `font name <https://kivymd.readthedocs.io/en/latest/components/bottomnavigation/#kivymd.uix.bottomnavigation.bottomnavigation.MDBottomNavigation.font_name>`_ for the `MDBottomNavigation <https://kivymd.readthedocs.io/en/latest/components/bottomnavigation/>`_ class;
* Rename `MDToolbarr` to `MDTopAppBar <https://kivymd.readthedocs.io/en/latest/components/toolbar/#kivymd.uix.toolbar.toolbar.MDTopAppBar>`_ class;
* Rename `MDToolbar` to `MDTopAppBar <https://kivymd.readthedocs.io/en/latest/components/toolbar/#kivymd.uix.toolbar.toolbar.MDTopAppBar>`_ class;
* The `overflow behavior <https://kivymd.readthedocs.io/en/latest/components/toolbar/#kivymd.uix.toolbar.toolbar.MDTopAppBar.use_overflow>`_ from the `ActionBar` class of the `Kivy` framework has been added to the `MDTopAppBar` class;
* Add `shift_right` and `shift_right` attributes to `MDTooltip <https://kivymd.readthedocs.io/en/latest/components/tooltip/>`_ class;
* Add `shift_right` and `shift_right` attributes to `MDTooltip class <https://kivymd.readthedocs.io/en/latest/components/tooltip/>`_;
* Fixed the size of the `MDIconButton <https://kivymd.readthedocs.io/en/latest/components/button/#mdiconbutton>`_ icon when changing icon_size on mobile devices;
* Add new `MDSegmentedControl <https://kivymd.readthedocs.io/en/latest/components/segmentedcontrol/>`_ widget;
* Add `on_release/on_press` events to `MDSmartTile <https://kivymd.readthedocs.io/en/latest/components/imagelist/#kivymd.uix.imagelist.imagelist.MDSmartTile>`_ class;
Expand Down
8 changes: 4 additions & 4 deletions docs/sources/changelog/1.1.1.rst
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,13 @@
* Bug fixes and other minor improvements.
* Add `closing_interval <https://kivymd.readthedocs.io/en/latest/components/card/#kivymd.uix.card.card.MDCardSwipe.closing_interval>`_ parameter to `MDCardSwipe <https://kivymd.readthedocs.io/en/latest/components/card/#kivymd.uix.card.card.MDCardSwipe>`_ class.
* Add implementation of elevation behavior on shaders.
* Add `validator <https://kivymd.readthedocs.io/en/latest/components/textfield/#kivymd.uix.textfield.textfield.MDTextField.validator>`_ property to `MDTextField <https://kivymd.readthedocs.io/en/latest/components/textfield/#kivymd.uix.textfield.textfield.MDTextFieldR>`_ class: the type of text field for entering Email, time, etc. Automatically sets the type of the text field as `error` if the user input does not match any of the set validation types.
* Add `validator <https://kivymd.readthedocs.io/en/latest/components/textfield/#kivymd.uix.textfield.textfield.MDTextField.validator>`_ `property to MDTextField <https://kivymd.readthedocs.io/en/latest/components/textfield/#kivymd.uix.textfield.textfield.MDTextFieldR>`_ class: the type of text field for entering Email, time, etc. Automatically sets the type of the text field as `error` if the user input does not match any of the set validation types.
* Add `theme_style_switch_animation <https://kivymd.readthedocs.io/en/latest/themes/theming/#kivymd.theming.ThemeManager.theme_style_switch_animation>`_ property to animate the colors of the application when switching the color scheme of the application `('Dark/light')`.
* Add `theme_style_switch_animation_duration <https://kivymd.readthedocs.io/en/latest/themes/theming/#kivymd.theming.ThemeManager.theme_style_switch_animation_duration>`_ property to duration of the animation of switching the color scheme of the application `("Dark/ light")`.
* `Fix <https://github.com/kivymd/KivyMD/issues/1332>`_ memory leak when dynamically adding and removing `KivyMD` widgets.
* `Fix <https://github.com/kivymd/KivyMD/pull/1344>`_ `MDBottomNavigation <https://kivymd.readthedocs.io/en/latest/components/bottomnavigation/>`_ slide transition direction.
* `Fix memory leak <https://github.com/kivymd/KivyMD/issues/1332>`_ when dynamically adding and removing `KivyMD` widgets.
* `Fix slide transition <https://github.com/kivymd/KivyMD/pull/1344>`_ `MDBottomNavigation <https://kivymd.readthedocs.io/en/latest/components/bottomnavigation/>`_ direction.
* Add a default value for the `icon <https://kivymd.readthedocs.io/en/latest/themes/material-app/#kivymd.app.MDApp.icon>`_ attribute of `MDApp <https://kivymd.readthedocs.io/en/latest/themes/material-app/#kivymd.app.MDApp>`_ class.
* Add new properties to `MDFileManager <https://kivymd.readthedocs.io/en/latest/components/filemanager/>`_ class:
* `Add new properties to MDFileManager <https://kivymd.readthedocs.io/en/latest/components/filemanager/>`_ class:

- `icon_selection_button <https://kivymd.readthedocs.io/en/latest/components/filemanager/#kivymd.uix.filemanager.filemanager.MDFileManager.icon_selection_button>`_ - icon that will be used on the directory selection button;
- `background_color_selection_button <https://kivymd.readthedocs.io/en/latest/components/filemanager/#kivymd.uix.filemanager.filemanager.MDFileManager.background_color_selection_button>`_ - background color of the current directory/path selection button;
Expand Down
1 change: 0 additions & 1 deletion docs/sources/changelog/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ Changelog
.. include:: /changelog/unreleased.rst
.. include:: /changelog/2.0.0.rst
.. include:: /changelog/1.1.1.rst
.. include:: /changelog/1.1.0.rst
.. include:: /changelog/1.0.2.rst
.. include:: /changelog/1.0.1.rst
.. include:: /changelog/1.0.0.rst
Expand Down
Loading

0 comments on commit 6623c8d

Please sign in to comment.