Also, the current behavior of CodeMirror regarding "select and hit any of
(,[,{, ),],}" is the same as what VSCode does, which uses a completely
different editor than CodeMirror (Monaco). It's nice to maintain
compatibility with other editors.
On Sunday, September 6, 2020 at 11:22:51 AM UTC-7 William Stein wrote:
> Quick comment: you can still type open parenthesis at the *end* of the
> selection, and Codemirror will correctly put parenthesis around the
> selection. I.e., almost exactly what you want already exists as long as
> you type "(" right where you were thinking of typing ")".
>
> On Sunday, September 6, 2020 at 2:17:09 AM UTC-7 Daniel Volinski wrote:
>
>> Does that feature exist in CodeMirror?
>>
>> Daniel
>>
>>
>> On Monday, March 19, 2018 at 1:09:35 PM UTC+2 takowl wrote:
>>
>>> The JS text editor component we use is called CodeMirror. If CodeMirror
>>> already has an option to do what you want, we can probably find a way to
>>> enable it. Otherwise, you'd need to convince CodeMirror to add the feature
>>> first.
>>>
>>> On 18 March 2018 at 08:23, 'Daniel Volinski' via Project Jupyter <
>>> [email protected]> wrote:
>>>
>>>> Hi All,
>>>>
>>>> I'm using SageMath 8.1 on Windows 10 Native with Jupyter Notebook.
>>>>
>>>> When I select text on a code cell and punch on any key on the keyboard,
>>>> the selected text is erased and that key is issued instead. Except for the
>>>> opening parenthesis, in its case, the selected text is enclosed by an
>>>> opening parenthesis at its left and a closing parenthesis at its right.
>>>> That is awesome. It saves me from going to other side of the text and add
>>>> the closing parenthesis by myself.
>>>>
>>>> Why not doing the same for the closing parenthesis? Right now, punching
>>>> the closing parenthesis erases the selected text like any other key. I
>>>> would like the closing parenthesis to be treated with the same respect as
>>>> the opening parenthesis, that is, when I select text, (usually from left
>>>> to
>>>> right) my cursor is already at the right of the selected text. I want to
>>>> punch the closing parenthesis and I want SageMath to add the opening
>>>> parenthesis at the beginning of the selected text, saving me time once
>>>> again.
>>>>
>>>> This should be equally valid for rectangular and curly parenthesis.
>>>>
>>>> Daniel
>>>>
>>>>
>>>> --
>>>> You received this message because you are subscribed to the Google
>>>> Groups "Project Jupyter" group.
>>>>
>>> To unsubscribe from this group and stop receiving emails from it, send
>>>> an email to [email protected].
>>>
>>>
>>>> To post to this group, send email to [email protected].
>>>> To view this discussion on the web visit
>>>> https://groups.google.com/d/msgid/jupyter/ef3e9051-36a6-4829-999c-eabd127d36ce%40googlegroups.com
>>>>
>>>> <https://groups.google.com/d/msgid/jupyter/ef3e9051-36a6-4829-999c-eabd127d36ce%40googlegroups.com?utm_medium=email&utm_source=footer>
>>>> .
>>>> For more options, visit https://groups.google.com/d/optout.
>>>>
>>>
--
You received this message because you are subscribed to the Google Groups
"Project Jupyter" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/jupyter/44e03eb2-b653-411f-8bc0-44d642379fafn%40googlegroups.com.