File tree Expand file tree Collapse file tree
src/main/kotlin/ai/devchat/idea Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -54,7 +54,9 @@ internal class DevChatToolWindowContent(project: Project) {
5454 // TODO: 'return' is not allowed here
5555 // return
5656 }
57- val jbCefBrowser = JBCefBrowser ()
57+ val jbCefBrowser = JBCefBrowserBuilder ()
58+ .setOffScreenRendering(false )
59+ .build()
5860 content.add(jbCefBrowser.component, BorderLayout .CENTER )
5961
6062
@@ -138,10 +140,7 @@ internal class DevChatToolWindowContent(project: Project) {
138140 " --vscode-foreground:" + colorToCssRgb(foregroundColor) + " ;" +
139141 " }" + " </style>"
140142 if (index != - 1 && endIndex != - 1 ) {
141- html = """
142- ${html.substring(0 , index + " <head>" .length)}
143- $styleTag${html.substring(endIndex)}
144- """ .trimIndent()
143+ html = html.substring(0 , endIndex) + styleTag + html.substring(endIndex)
145144 }
146145 return html
147146 }
You can’t perform that action at this time.
0 commit comments