Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot show auto-completion for keywords starting with # #1

Open
CXuesong opened this issue May 13, 2017 · 0 comments
Open

Cannot show auto-completion for keywords starting with # #1

CXuesong opened this issue May 13, 2017 · 0 comments

Comments

@CXuesong
Copy link
Owner

Client request:

{
    "id": 8,
    "method": "textDocument/completion",
    "params": {
        "textDocument": {
            "uri": "file:///.../_private/Untitled-1.mediawiki"
        },
        "position": {
            "line": 0,
            "character": 5
        }
    },
    "jsonrpc": "2.0"
}

Server response:

{
    "id": 8,
    "result": {
        "isIncomplete": true,
        "items": [
            {
                "label": "#if",
                "kind": 14,
                "detail": "Evaluates a test string and determines whether or not it is empty.",
                "documentation": null,
                "sortText": null,
                "filterText": null,
                "insertText": null,
                "insertTextFormat": 1,
                "textEdit": null,
                "additionalTextEdits": null,
                "command": null,
                "data": "#if"
            },
            {
                "label": "#ifeq",
                "kind": 14,
                "detail": "Compares two strings and determines whether they are identical.",
                "documentation": null,
                "sortText": null,
                "filterText": null,
                "insertText": null,
                "insertTextFormat": 1,
                "textEdit": null,
                "additionalTextEdits": null,
                "command": null,
                "data": "#ifeq"
            },
            {
                "label": "Tocright",
                "kind": 3,
                "detail": "Inferred page information.",
                "documentation": null,
                "sortText": null,
                "filterText": null,
                "insertText": null,
                "insertTextFormat": 1,
                "textEdit": null,
                "additionalTextEdits": null,
                "command": null,
                "data": "Tocright"
            },
            {
                "label": "Navbox",
                "kind": 3,
                "detail": "Inferred page information.",
                "documentation": null,
                "sortText": null,
                "filterText": null,
                "insertText": null,
                "insertTextFormat": 1,
                "textEdit": null,
                "additionalTextEdits": null,
                "command": null,
                "data": "Navbox"
            },
            {
                "label": "Portal bar",
                "kind": 3,
                "detail": "Inferred page information.",
                "documentation": null,
                "sortText": null,
                "filterText": null,
                "insertText": null,
                "insertTextFormat": 1,
                "textEdit": null,
                "additionalTextEdits": null,
                "command": null,
                "data": "Portal bar"
            },
            {
                "label": "Temporary",
                "kind": 3,
                "detail": "Inferred page information.",
                "documentation": null,
                "sortText": null,
                "filterText": null,
                "insertText": null,
                "insertTextFormat": 1,
                "textEdit": null,
                "additionalTextEdits": null,
                "command": null,
                "data": "Temporary"
            },
            {
                "label": "Navbox subgroup",
                "kind": 3,
                "detail": "Inferred page information.",
                "documentation": null,
                "sortText": null,
                "filterText": null,
                "insertText": null,
                "insertTextFormat": 1,
                "textEdit": null,
                "additionalTextEdits": null,
                "command": null,
                "data": "Navbox subgroup"
            },
            {
                "label": "LT",
                "kind": 3,
                "detail": "Inferred page information.",
                "documentation": null,
                "sortText": null,
                "filterText": null,
                "insertText": null,
                "insertTextFormat": 1,
                "textEdit": null,
                "additionalTextEdits": null,
                "command": null,
                "data": "LT"
            },
            {
                "label": "Override",
                "kind": 3,
                "detail": "Inferred page information.",
                "documentation": null,
                "sortText": null,
                "filterText": null,
                "insertText": null,
                "insertTextFormat": 1,
                "textEdit": null,
                "additionalTextEdits": null,
                "command": null,
                "data": "Override"
            }
        ]
    },
    "jsonrpc": "2.0"
}

But nothing is shown in the editor.
sharp-if

On the other hand, if I type something starting with letter, the auto-completion functions as expected.
disp

Client request:

{
    "id": 11,
    "method": "textDocument/completion",
    "params": {
        "textDocument": {
            "uri": "file:///.../_private/Untitled-1.mediawiki"
        },
        "position": {
            "line": 0,
            "character": 6
        }
    },
    "jsonrpc": "2.0"
}

Server response:

{
    "id": 11,
    "result": {
        "isIncomplete": true,
        "items": [
            {
                "label": "DISPLAYTITLE",
                "kind": 14,
                "detail": "Format the current page's title header. The value must be equivalent to the default title: only capitalization changes to certain parts of the title (not all) and replacing spaces with underscores are allowed.",
                "documentation": null,
                "sortText": null,
                "filterText": null,
                "insertText": null,
                "insertTextFormat": 1,
                "textEdit": null,
                "additionalTextEdits": null,
                "command": null,
                "data": "DISPLAYTITLE"
            },
            {
                "label": "Tocright",
                "kind": 3,
                "detail": "Inferred page information.",
                "documentation": null,
                "sortText": null,
                "filterText": null,
                "insertText": null,
                "insertTextFormat": 1,
                "textEdit": null,
                "additionalTextEdits": null,
                "command": null,
                "data": "Tocright"
            },
            {
                "label": "Override",
                "kind": 3,
                "detail": "Inferred page information.",
                "documentation": null,
                "sortText": null,
                "filterText": null,
                "insertText": null,
                "insertTextFormat": 1,
                "textEdit": null,
                "additionalTextEdits": null,
                "command": null,
                "data": "Override"
            },
            {
                "label": "Portal bar",
                "kind": 3,
                "detail": "Inferred page information.",
                "documentation": null,
                "sortText": null,
                "filterText": null,
                "insertText": null,
                "insertTextFormat": 1,
                "textEdit": null,
                "additionalTextEdits": null,
                "command": null,
                "data": "Portal bar"
            },
            {
                "label": "Temporary",
                "kind": 3,
                "detail": "Inferred page information.",
                "documentation": null,
                "sortText": null,
                "filterText": null,
                "insertText": null,
                "insertTextFormat": 1,
                "textEdit": null,
                "additionalTextEdits": null,
                "command": null,
                "data": "Temporary"
            },
            {
                "label": "LT",
                "kind": 3,
                "detail": "Inferred page information.",
                "documentation": null,
                "sortText": null,
                "filterText": null,
                "insertText": null,
                "insertTextFormat": 1,
                "textEdit": null,
                "additionalTextEdits": null,
                "command": null,
                "data": "LT"
            },
            {
                "label": "Navbox subgroup",
                "kind": 3,
                "detail": "Inferred page information.",
                "documentation": null,
                "sortText": null,
                "filterText": null,
                "insertText": null,
                "insertTextFormat": 1,
                "textEdit": null,
                "additionalTextEdits": null,
                "command": null,
                "data": "Navbox subgroup"
            },
            {
                "label": "Navbox",
                "kind": 3,
                "detail": "Inferred page information.",
                "documentation": null,
                "sortText": null,
                "filterText": null,
                "insertText": null,
                "insertTextFormat": 1,
                "textEdit": null,
                "additionalTextEdits": null,
                "command": null,
                "data": "Navbox"
            }
        ]
    },
    "jsonrpc": "2.0"
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant