package com.github.ohtomi.sandbox;

import com.intellij.openapi.fileEditor.impl.EditorTabColorProvider;
import com.intellij.openapi.project.Project;
import com.intellij.openapi.vfs.VirtualFile;
import com.intellij.ui.JBColor;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;

import java.awt.*;

public class MyEditorTabColorProvider implements EditorTabColorProvider {

    @Nullable
    @Override
    public Color getEditorTabColor(@NotNull Project project, @NotNull VirtualFile file) {
        System.out.println("getEditorTabColor(@NotNull Project project, @NotNull VirtualFile file)");
        switch (file.getFileType().getDefaultExtension()) {
            case "txt":
                return JBColor.GREEN;
            case "xml":
                return JBColor.BLUE;
            case "java":
                return JBColor.YELLOW;
            default:
                return null;
        }
    }
}

@@ -932,11 +932,549 @@
  %7D%0A    %7D
+%0A%0A    @Nullable%0A    @Override%0A    public Color getProjectViewColor(@NotNull Project project, @NotNull VirtualFile file) %7B%0A        System.out.println(%22getProjectViewColor(@NotNull Project project, @NotNull VirtualFile file)%22);%0A        switch (file.getFileType().getDefaultExtension()) %7B%0A            case %22txt%22:%0A                return JBColor.GREEN;%0A            case %22xml%22:%0A                return JBColor.BLUE;%0A            case %22java%22:%0A                return JBColor.YELLOW;%0A            default:%0A                return null;%0A        %7D%0A    %7D
 %0A%7D%0A

Change color of background of project view