mirror of
https://gitflic.ru/project/openide/openide.git
synced 2025-12-12 13:40:19 +07:00
PY-78524 Fix problem with codeCellBackgroundColor undefined because of plugin from master
GitOrigin-RevId: c69fc1ec54eb253ceb40bbb9e91851662e84fdce
This commit is contained in:
committed by
intellij-monorepo-bot
parent
c88308938b
commit
0596355a2e
@@ -3,8 +3,10 @@ package com.intellij.notebooks.ui.visualization
|
||||
|
||||
import com.intellij.openapi.editor.Editor
|
||||
import com.intellij.openapi.editor.colors.ColorKey
|
||||
import com.intellij.openapi.editor.colors.EditorColorsManager
|
||||
import com.intellij.openapi.editor.colors.EditorColorsScheme
|
||||
import com.intellij.openapi.editor.impl.EditorImpl
|
||||
import com.intellij.openapi.observable.properties.ObservableProperty
|
||||
import com.intellij.openapi.util.Key
|
||||
import com.intellij.ui.JBColor
|
||||
import com.intellij.ui.NewUiValue
|
||||
@@ -72,6 +74,16 @@ interface NotebookEditorAppearanceSizes {
|
||||
interface NotebookEditorAppearanceColors {
|
||||
// TODO Sort everything lexicographically.
|
||||
|
||||
// it is a temporary hack to avoid PY-78524 (will be removed in future)
|
||||
val codeCellBackgroundColor: ObservableProperty<Color>
|
||||
get() {
|
||||
return object : ObservableProperty<Color> {
|
||||
override fun get(): Color {
|
||||
return getCodeCellBackground(EditorColorsManager.getInstance().globalScheme) ?: JBColor.BLACK
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
fun getCodeCellBackground(scheme: EditorColorsScheme): Color? = scheme.defaultBackground
|
||||
fun getGutterInputExecutionCountForegroundColor(scheme: EditorColorsScheme): Color? = null
|
||||
fun getGutterOutputExecutionCountForegroundColor(scheme: EditorColorsScheme): Color? = null
|
||||
|
||||
Reference in New Issue
Block a user