Pakete, Repositories und App-Kategorien suchen

Cover von utils_rinch_text
Paketdetailsv1.0.3

utils_rinch_text

Diese Methode gibt eine Liste von TextSpan zurück, die ideal für die Formatierung langer Texte ist. Diese Implementierung unterstützt die folgenden Tags, siehe Beispiel.

AndroidiOSWebmacOSWindowsLinux
30-Tage-Downloads
19
Likes
9
Pub-Punkte
160

Paket installieren

flutter pub add utils_rinch_text

Paketübersicht

Aus öffentlichen Paketdaten erstellte Orientierung.

Das utils_rinch_text-Paket bietet eine Hilfsmethode zur Formatierung langer Texte mithilfe von TextSpan und unterstützt benutzerdefinierte Tags für die Darstellung von Rich-Text. Es ermöglicht die strukturierte Anzeige von Text mit eingebetteter Formatierung und ist ideal für dynamische Inhalte wie Chat-Nachrichten oder formatierte Beschreibungen. Das Paket ist auf allen wichtigen Plattformen kompatibel und vereinfacht die Erstellung komplexer Textlayouts ohne manuelle Span-Verwaltung. Es nutzt eine saubere API, um markierten Text effizient zu parsen und darzustellen.

Anwendungsfälle

  • Chat-Nachrichtenformatierung
  • Dynamische Inhaltsdarstellung
  • Rich Text in Benutzeroberflächenkomponenten
  • Formatierte Beschreibungen
  • Benutzererzeugter Textverarbeitung

Hauptmerkmale

  • Unterstützt benutzerdefinierte Text-Tags
  • Generiert TextSpan-Listen
  • Plattformübergreifende Kompatibilität
  • Einfache API-Integration
  • Effiziente Textanalyse

Geeignet für

  • Apps mit Bedarf an reichhaltigem Text
  • Chat- oder Nachrichtenoberflächen
  • inhaltsreiche Benutzeroberfläche
  • Textformatierungswerkzeuge
  • Flutter-Entwickler, die Einfachheit suchen

Hinweise

  • Erforderliche korrekte Tag-Syntax
  • Beschränkt auf Textformatierung nur
  • Keine integrierten Stiloptionen
  • Abhängig von der korrekten Eingabestruktur
  • Nicht geeignet für komplexe Layouts

Original-README

Originaler README-Schnappschuss aus dem verknüpften Quell-Repository. Aktuelle Inhalte finden Sie im Repository.

This method returns a list of TextSpan ideal for formatting long text this implementation supports the following tags, see example.

<a>Link web<a>
<p> add paragraph

Captura de tela 2023-02-03 195339

Add custom tags

Text de example:

 String textExample = """
  <i>Flutter<i> is an open source mobile app development framework <l>created by Google.<l> 
  It enables the creation of native apps for <i>iOS and Android<i> with a single Dart code base. 
  With its flexible and performant architecture, <o>Flutter has become one of the most 
  popular options for building mobile apps.<o> In addition, it offers a wide range of widgets 
  and animated visual effects that help you create attractive and intuitive applications. <p>
  For more information about Flutter, head over to the main 
  page at <a>https://flutter.dev/<a> and start <b>exploring the possibilities<b> 
  of this powerful app development tool.
  """;

Implementation

RichText(
   text: TextSpan(
     children: UtilsRinchText.generate(
       textExample,
       customTags: {
         "<i>": const TextStyle(
           fontWeight: FontWeight.bold,
           fontSize: 20,
         ),
         "<l>": const TextStyle(
           fontSize: 20,
           color: Colors.red,
           fontWeight: FontWeight.bold,
         ),
         "<a>": const TextStyle(
           color: Colors.green,
           fontWeight: FontWeight.bold,
         ),
         "<o>": const TextStyle(
           fontWeight: FontWeight.bold,
           color: Colors.blue,
           fontSize: 20,
         ),
         "<b>": const TextStyle(
           fontWeight: FontWeight.bold,
           color: Colors.orange,
           fontSize: 20,
         ),
       },
     ),
   ),
 ), 

Kategorien

Abhängigkeiten

Abhängigkeiten 1 Einträge

Quell-Repository

Projekte, die dieses Paket verwenden

Noch keine Daten verfügbar.