# How to custom unicode completions?

**URL:** https://discourse.julialang.org/t/how-to-custom-unicode-completions/113304
**Category:** General Usage
**Tags:** question, unicode
**Created:** [April 21, 2024, 12:21pm UTC](https://discourse.julialang.org/t/how-to-custom-unicode-completions/113304 "2024-04-21T12:21:50Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![NeroBlackstone](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/neroblackstone/32/208679_2.png) [@NeroBlackstone](https://discourse.julialang.org/u/NeroBlackstone)
#### Post date: [April 21, 2024, 12:21pm UTC](https://discourse.julialang.org/t/how-to-custom-unicode-completions/113304/1 "2024-04-21T12:21:50Z")

</div>

I want to add 𝄫(double flat) and 𝄪(double sharp) to REPL unicode completion, but I don’t know how to do.

I found this in [github](https://github.com/JuliaLang/julia/issues/21646#issuecomment-299280424), but it seems that the Base module does not export the REPLCompletions submodule, and the REPLCompletions module does not export latex\_symbols, so latex\_symbols cannot be modified directly in startup.jl

---

<div class="post-metadata">

### Author: ![cormullion](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/cormullion/32/49131_2.png) [@cormullion](https://discourse.julialang.org/u/cormullion)
#### Post date: [April 21, 2024, 5:17pm UTC](https://discourse.julialang.org/t/how-to-custom-unicode-completions/113304/2 "2024-04-21T17:17:09Z")

</div>

Perhaps add to your ~/.julia/config/startup.jl :

```julia
using REPL
atreplinit() do repl
    REPL.REPLCompletions.latex_symbols["\\dflat"] = "𝄫"
end

```

---

<div class="post-metadata">

### Author: ![stevengj](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/stevengj/32/71_2.png) [@stevengj](https://discourse.julialang.org/u/stevengj)
#### Post date: [April 21, 2024, 5:28pm UTC](https://discourse.julialang.org/t/how-to-custom-unicode-completions/113304/3 "2024-04-21T17:28:33Z")

</div>

> [@cormullion](#):
>
> `atreplinit() do repl`

I don’t think you have to wait for the REPL to be initialized — you should just do it immediately:

```julia
import REPL
REPL.REPLCompletions.latex_symbols["\\dflat"] = "𝄫"

```

> [@NeroBlackstone](#):
>
> I want to add 𝄫(double flat) and 𝄪(double sharp) to REPL unicode completion

It would be reasonable to add `\doubleflat` and `\doublesharp` (or maybe `\flat2` and `\sharp2`, or …?) to the global table in a future version. Just submit a patch to [`REPL/src/latex_symbols.jl`](https://github.com/JuliaLang/julia/blob/aad72458539946bc7f2b1d1f6092f963fed4bd8c/stdlib/REPL/src/latex_symbols.jl#L809-L813). We’re pretty permissive about adding new symbol tab completions.

---

<div class="post-metadata">

### Author: ![NeroBlackstone](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/neroblackstone/32/208679_2.png) [@NeroBlackstone](https://discourse.julialang.org/u/NeroBlackstone)
#### Post date: [April 22, 2024, 3:58am UTC](https://discourse.julialang.org/t/how-to-custom-unicode-completions/113304/4 "2024-04-22T03:58:25Z")

</div>

Thank you for your reply! Very useful.

I have opened a [pull request](https://github.com/JuliaLang/julia/pull/54182) for adding these musical symbols.
