Repository: sublimelsp/LSP

Issue:
Don't use emoji for "deprecated" completion icon
I saw that LSP-typescript marks certain completion items as "deprecated", and LSP uses the warning sign emoji (U+26A0) for the completion icon:

https://github.com/sublimelsp/LSP/blob/039b389d8ca8977f1bf308bd598804a5fe39a345/plugin/core/views.py#L879

![default](https://user-images.githubusercontent.com/6579999/153267364-e866c1a9-d320-46e0-b46f-1c0fbada80ca.png)
(Default Dark theme)

I assume the icon comes from the Segoe UI Emoji font on Windows.

In my opinion, it looks out of place compared to the regular letters, and is quite ugly (especially due to the italic font style of the kind icons in the Default & Adaptive themes) and is a bit distracting. 

But even worse for me is, that transparency doesn't seem to work with emojis. This results in the deprecated icons appearing kind of "broken" in my own theme:

![brackets](https://user-images.githubusercontent.com/6579999/153269314-cd264707-1c46-430f-a9c8-1b6c5a642649.png)

Would it be sufficient to show the warning sign emoji only in the details pane at the bottom, and use a non-emoji character for the kind icon? I would suggest to use an exclamation mark for deprecated items:

![default2](https://user-images.githubusercontent.com/6579999/153271439-be1de501-f50e-453d-a5cf-e58449a92fce.png)

An alternative I've found could be [Circled Division Slash](https://unicode-table.com/en/2298/) (U+2298, ⊘ ), but I think that one doesn't look as nice with the italic font style in most themes.
![default3](https://user-images.githubusercontent.com/6579999/153272470-bc616c0b-cf64-45ed-b02c-c574d9b09d80.png)

Is it okay to change it to the exclamation mark? I could provide a PR.



Discussion:

Resolving patch:
diff --git a/plugin/core/views.py b/plugin/core/views.py
--- a/plugin/core/views.py
+++ b/plugin/core/views.py
@@ -876,7 +876,7 @@ def format_completion(
         kind = sublime.KIND_AMBIGUOUS
 
     if _is_completion_item_deprecated(item):
-        kind = (kind[0], '⚠', "⚠ {} - Deprecated".format(kind[2]))
+        kind = (kind[0], '!', "⚠ {} - Deprecated".format(kind[2]))
 
     lsp_label = item["label"]
     lsp_label_details = item.get("labelDetails")


Test patch:
diff --git a/tests/test_completion.py b/tests/test_completion.py
--- a/tests/test_completion.py
+++ b/tests/test_completion.py
@@ -612,7 +612,7 @@ def test_show_deprecated_flag(self) -> None:
             "deprecated": True
         }  # type: CompletionItem
         formatted_completion_item = format_completion(item_with_deprecated_flag, 0, False, "")
-        self.assertEqual('⚠', formatted_completion_item.kind[1])
+        self.assertEqual('!', formatted_completion_item.kind[1])
         self.assertEqual('⚠ Method - Deprecated', formatted_completion_item.kind[2])
 
     def test_show_deprecated_tag(self) -> None:
@@ -622,7 +622,7 @@ def test_show_deprecated_tag(self) -> None:
             "tags": [CompletionItemTag.Deprecated]
         }  # type: CompletionItem
         formatted_completion_item = format_completion(item_with_deprecated_tags, 0, False, "")
-        self.assertEqual('⚠', formatted_completion_item.kind[1])
+        self.assertEqual('!', formatted_completion_item.kind[1])
         self.assertEqual('⚠ Method - Deprecated', formatted_completion_item.kind[2])
 
     def test_strips_carriage_return_in_insert_text(self) -> 'Generator':