quran_controller 1.6.8

SDKflutter
Platformandroidioswindowslinuxmacosweb

Quran Controller that offering a Quran Verses With Quran font which is Called Uthmani script

Quran Controller


Quran Controller that offering a Quran Verses With Quran font which is Called Uthmani script


Content

Installation

Add the package to your dependencies:

dependencies:
  quran_controller: ^1.6.8

OR

dependencies:
  quran_controller:
    git: https://github.com/hassony105/quran_controller.git

Finally, run dart pub get to download the package.

Projects using this library should use the stable channel of Flutter

Get Started

You must to initialize QuranController by calling await QuranController.instance.initializing(); because it takes a few seconds to load all verses.

Methods And Properties

PropertiesTypeDescription
initializing()Future<void>Required. initialize QuranController
gettingVersesByPageNumber(int pageNumber)List<Verse>Returns list of Verses filtered by page number
gettingVersesBySurahNumber(int surahNumber)SurahReturns Surah by given number
gettingVersesByJuzNumber(int juzNumber)JuzReturns Juz by given number
gettingVerseByVerseKey(String key)VerseReturns Verse by given key
search(String text)Future<List<Verse>>Returns list of Verses filtered by given text
getSurahName(int surahNumber)StringReturns String from the charcode of surah name
instanceQuranControllerAn Instance of QuranController
allVersesList<Verse>A list of Verses that loaded after initializing
surahsDetailsList<Surah>A list of Surahs that contains each Surah details
juzsDetailsList<Juz>A list of Juzs that contains each Juz details
basmalaTextStringThe unicode character of Basmala
surahTextStringThe unicode character of "Surah" word
borderTextStringThe unicode character of Border of Surah name
basmalaAndSurahsNameFontsFamilyStringThe Font Family Basmala and Surahs names

How To Use

It is very simple to use, just like these examples:

Require: You must to use the fontFamily in TextStyle to get Quran styled text.

  • Basmala
Text(
    QuranController.instance.basmalaText,
    style: TextStyle(fontFamily: QuranController.instance.basmalaAndSurahsNameFontsFamily),
)

  • "Surah" Word
Text(
    QuranController.instance.surahText,
    style: TextStyle(fontFamily: QuranController.instance.basmalaAndSurahsNameFontsFamily),
)

  • Border
Text(
    QuranController.instance.borderText,
    style: TextStyle(fontFamily: QuranController.instance.basmalaAndSurahsNameFontsFamily),
)

  • Verse
Text(
    verse.fullVerse,
    style: TextStyle(fontFamily: verse.font),
)

Localization

Quran Controller package currently supports only Arabic language view.

Contribution

Feel free to file an issue if you find a problem or make pull requests.

All contributions are welcome :)