Merge pull request #3717 from continuedev/pe/jb-tooltip-placement-bugfix

bugfix(jb): handle tabs in tooltip placement x offset
This commit is contained in:
Patrick Erichsen 2025-01-13 21:37:56 -08:00 • committed by GitHub
commit c3bfd5b73c
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 31 additions and 31 deletions

View file

@ -1,31 +1,31 @@
<component name="ProjectRunConfigurationManager">
<configuration default="false" name="Run Extension" type="GradleRunConfiguration" factoryName="Gradle">
<ExternalSystemSettings>
<option name="env">
<map>
<entry key="GUI_URL" value="http://localhost:5173/jetbrains_index.html" />
<entry key="ORG_GRADLE_PROJECT_platformVersion" value="2024.1" />
<entry key="USE_TCP" value="true" />
</map>
</option>
<option name="executionName" />
<option name="externalProjectPath" value="$PROJECT_DIR$" />
<option name="externalSystemIdString" value="GRADLE" />
<option name="scriptParameters" value="" />
<option name="taskDescriptions">
<list />
</option>
<option name="taskNames">
<list>
<option value="runIde" />
</list>
</option>
<option name="vmOptions" />
</ExternalSystemSettings>
<ExternalSystemDebugServerProcess>true</ExternalSystemDebugServerProcess>
<ExternalSystemReattachDebugProcess>true</ExternalSystemReattachDebugProcess>
<DebugAllEnabled>false</DebugAllEnabled>
<RunAsTest>false</RunAsTest>
<method v="2" />
</configuration>
<configuration default="false" name="Run Extension" type="GradleRunConfiguration" factoryName="Gradle">
<ExternalSystemSettings>
<option name="env">
<map>
<entry key="GUI_URL" value="http://localhost:5173/jetbrains_index.html"/>
<entry key="ORG_GRADLE_PROJECT_platformVersion" value="2024.1"/>
<entry key="USE_TCP" value="true"/>
</map>
</option>
<option name="executionName"/>
<option name="externalProjectPath" value="$PROJECT_DIR$/extensions/intellij"/>
<option name="externalSystemIdString" value="GRADLE"/>
<option name="scriptParameters" value=""/>
<option name="taskDescriptions">
<list/>
</option>
<option name="taskNames">
<list>
<option value="runIde"/>
</list>
</option>
<option name="vmOptions"/>
</ExternalSystemSettings>
<ExternalSystemDebugServerProcess>true</ExternalSystemDebugServerProcess>
<ExternalSystemReattachDebugProcess>true</ExternalSystemReattachDebugProcess>
<DebugAllEnabled>false</DebugAllEnabled>
<RunAsTest>false</RunAsTest>
<method v="2"/>
</configuration>
</component>

View file

@ -179,8 +179,8 @@ class ContinuePluginSelectionListener(
val lineStartOffset = document.getLineStartOffset(lineNumber)
val lineEndOffset = document.getLineEndOffset(lineNumber)
val lineText = document.getText(TextRange(lineStartOffset, lineEndOffset)).trimEnd()
val endOfLinePos = LogicalPosition(lineNumber, lineText.length)
return editor.logicalPositionToXY(endOfLinePos).x
val visualPosition = editor.offsetToVisualPosition(lineStartOffset + lineText.length)
return editor.visualPositionToXY(visualPosition).x
}
val offset = 40