Nodes/๐Ÿ”ค๏ธ CR Arabic Text RTL
ComfyUI Node

๐Ÿ”ค๏ธ CR Arabic Text RTL

Arabic text renders as scrambled spaghetti in your image? This node fixes the order

๐Ÿ”ค๏ธ CR Arabic Text RTL
    • arabic_text_rtl
    • show help
    โ—„arabic_textุดู…ุณโ–บ

    Type Arabic into a ComfyUI text box, pipe it into a text-drawing node, and what comes out is usually a jumbled mess: letters unconnected, words in the wrong visual order, numbers in the wrong place. That's not you doing it wrong - it's Unicode. Arabic is a right-to-left, cursive script, but the string you typed stores letters in logical order. Whatever you're using to render it (usually PIL) doesn't know that, so it draws everything left-to-right with isolated letterforms.

    CR Arabic Text RTL is a tiny text-prep node from Comfyroll Studio (the big "CR" pack by Suzie1 and RockOfFire) that fixes exactly that. You feed it the Arabic string, it hands back a reshaped, reordered version you can then drop into CR Draw Text, CR Overlay Text, or CR Composite Text and get legible Arabic on your generated image. That's the whole job, and it does it in one step.

    How it works

    Under the hood it's two well-known Python libraries doing the heavy lifting:

    1. arabic_reshaper.reshape() - takes the isolated Unicode codepoints and converts them to Arabic presentation forms, so letters actually join up the way the script requires.
    2. get_display() from python-bidi - reorders the logical string into correct visual right-to-left order, including digits and punctuation.

    The result is a plain STRING you treat like any other text. It never touches an image itself; it's purely a text-transformation step that sits upstream of the drawing nodes.

    The inputs and outputs

    The info schema is delightfully small:

    • arabic_text (STRING, multiline) - the only input that matters. Type or paste your Arabic here. The default is ุดู…ุณ ("shams", sun), handy for testing the pipeline end to end.
    • arabic_text_rtl (STRING) - the fixed text. Wire this into the text input of CR Draw Text or CR Composite Text.
    • show help (STRING) - a URL to the wiki page for the node. Ignore it; Comfyroll puts one of these on every node.

    Installing it

    Comfyroll installs like any other custom node pack:

    cd ComfyUI/custom_nodes
    git clone https://github.com/Suzie1/ComfyUI_Comfyroll_CustomNodes.git
    

    Then restart ComfyUI. Or skip the terminal entirely: open ComfyUI Manager โ†’ Install Custom Nodes and search for ComfyUI_Comfyroll_CustomNodes (it shows up as "Comfyroll Studio"). There's no requirements.txt - the core nodes run on stdlib, PIL, numpy, and torch, all of which ComfyUI already ships.

    One real dependency you will need for Arabic rendering specifically: an Arabic-capable font. PIL's default fonts render Arabic as tofu boxes. Comfyroll bundles NotoSansArabic-Regular.ttf in its fonts/ folder, and CR Draw Text's font_name dropdown lists it. Select that.

    The gotcha you'll actually hit

    Here's the thing nobody warns you about: in current Comfyroll v1.76 the node is commented out of the pack's node mappings. The class still exists in nodes_graphics_text.py, but node_mappings.py has it disabled, so on a fresh install it often won't even show up in your node menu - this comfy.icu page survives from an earlier version. The auto-install for arabic_reshaper and python-bidi is commented out too, which means if you re-enable the mapping yourself you also have to run:

    pip install arabic_reshaper python-bidi
    

    โ€ฆor the node crashes with a NameError the moment you execute it.

    So set expectations. Comfyroll went quiet in early 2024 (patch notes stop at v1.76, Jan 2024), and a lot of older shared workflows still lean on it, which is why Manager keeps it around. If you're running an older Comfyroll release, CR Arabic Text RTL genuinely works and is the cleanest way to get RTL order right. On a modern install, though, this node is effectively a historical artifact - don't install the whole pack just for it. You'll likely have an easier time reshaping the text yourself with a small Execute Python node, or just letting a newer, font-aware text workflow handle it. If it appears in your menu, great - enjoy the one node that makes Arabic posters not look broken. If it doesn't, you now know why.

    Category๐Ÿงฉ Comfyroll/๐Ÿ‘พ Graphics/๐Ÿ”ค Text

    Inputs (1)

    NameTypeDefaultDescription
    arabic_textSTRINGุดู…ุณโ€”

    Outputs (2)

    NameTypeDescription
    arabic_text_rtlSTRINGโ€”
    show helpSTRINGโ€”