Mixin Network Flutter Plugins

repository·main·Indexed 19 days ago

https://github.com/mixinnetwork/flutter-plugins

A collection of Flutter plugins optimized for the Mixin Messenger Desktop client. Includes packages for crash reporting (breakpad_client), window management (bring_window_to_front, desktop_multi_window, desktop_lifecycle), cryptographic primitives (common_crypto), file drag-and-drop (desktop_drop), and screen wake locks (desktop_keep_screen_on). Provides implementation details for Dart FFI plugins and native code invocation.

Tokens
19.9K
Snippets
68
Records
106
Agent score
67%

What's inside mixinnetwork-flutter-plugins

  1. Overview of mixin_markdown_widget

    main

    mixin_markdown_widget is a high-performance, desktop-first Flutter Markdown reader package. It is designed for high-quality reading surfaces and features highly customizable block-based rendering.

    Key capabilities include:

    • Streaming Support: Optimized for LLM responses using MarkdownController for incremental parsing.
    • Advanced Selection: A model-driven selection engine (MarkdownSelectionController) that supports word selection, block selection, and table cell range selection.
    • Rich Syntax: Supports CommonMark, GFM task lists, tables, footnotes, definition lists, math (TeX), and inline HTML.
    • Customization: Deep control over block rendering (code blocks, bullets, images), link handling, and theming via MarkdownThemeData.
  2. Use bring_window_to_front for Linux Wayland support

    main
    The bring_window_to_front package provides a solution for Linux applications, specifically addressing an issue on Wayland where GTK windows covered by other windows are not brought to the foreground when calling gtk_window_present. Use this package to ensure your Flutter application window can be brought to the front on Linux Wayland environments.
  3. Use CppJieba dictionaries for word segmentation

    main

    CppJieba uses different dictionaries depending on the segmentation algorithm selected:

    1. MPSegment (Max Probability): Uses jieba.dict.utf8 or jieba.dict.gbk.
    2. HMMSegment (Hidden Markov Model): Uses hmm_model.utf8 or hmm_model.gbk.
    3. MixSegment (Hybrid): Uses both jieba.dict and hmm_model dictionaries to combine the strengths of both algorithms.
  4. How to invoke native code in Flutter

    main

    When calling native functions via Dart FFI, consider the execution time of the function to maintain UI performance:

    • Short-running functions: Can be invoked directly from any isolate (e.g., simple arithmetic).
    • Long-running functions: Should be invoked on a helper isolate to prevent blocking the main thread and dropping frames in the Flutter application.