功率响应:
Not converting to markdown wouldn't be a good idea (as it prevents us from using markdown at all in the tooltips). VS Code's plaintext support is broken until 1.52, but maybe then we could add a toggle to say "use plaintext only".
我正在使用VSCode编写python,并使用Pylance提供智能。我想知道它是否能以一种简洁的方式提供自动包装的信息?目前提供的intellisense信息将所有内容混合在一行中,因此很难看到
更具体地说,下图显示了不带自动换行的intellisense。我希望Args:
和以下信息与绿色注释所写的内容完全相同(每行都是一个参数及其解释)。我怎样才能做到呢
图1:没有自动换行的用户定义类FDNN
的智能感知
图2:没有自动换行的pytorch类nn.Linear
的智能感知
编辑1:
删除注释前的r
无效
编辑2:
添加-
比纯文本效果更好,但面临_
转义问题
解决方案很简单:删除docstring前面的
r
编辑
我已经尝试了
r
函数的doc字符串,但无法重现该行为如果将文档字符串格式化为一种标记,则只有它具有problems with ^{} in variable names 时,它的显示效果才会更好
在标题行下面加上
-
(减号),这样文本就变得合理了对于函数,键入开头
(
后文档字符串的呈现方式不同,它在参数工具提示中用作文本这可能是为VSC创建问题的原因。不同提供者中的描述有不同的解释,应该可以将它们标记为纯文本或“标记”
相关问题 更多 >
编程相关推荐