Package com.intellij.execution.ui

Examples of com.intellij.execution.ui.ConsoleViewContentType


        try {
            OSProcessHandler osph = new OSProcessHandler(builder.start(), StringUtil.join(stopCommand, " "));
            osph.addProcessListener(new ProcessAdapter() {
                @Override
                public void onTextAvailable(final ProcessEvent event, Key outputType) {
                    ConsoleViewContentType contentType = ConsoleViewContentType.SYSTEM_OUTPUT;
                    if (outputType == ProcessOutputTypes.STDERR) {
                        contentType = ConsoleViewContentType.ERROR_OUTPUT;
                    }
                    console.print(event.getText(), contentType);
                }
View Full Code Here


        builder.directory(dir);
        OSProcessHandler osph = new OSProcessHandler(builder.start(), StringUtil.join(testCommand, " "));
        osph.addProcessListener(new ProcessAdapter() {
            @Override
            public void onTextAvailable(final ProcessEvent event, Key outputType) {
                ConsoleViewContentType contentType = ConsoleViewContentType.SYSTEM_OUTPUT;
                if (outputType == ProcessOutputTypes.STDERR) {
                    contentType = ConsoleViewContentType.ERROR_OUTPUT;
                }
                console.print(event.getText(), contentType);
            }
View Full Code Here

  private void start(@NotNull final Content consoleContent) {
    ArchivedOutputListener outputListener = new ArchivedOutputListener() {
      @Override
      public void onOutputAvailable(@NotNull String text, Key outputType, boolean archived) {
        ConsoleViewContentType contentType = ConsoleViewContentType.getConsoleViewType(outputType);
        myConsole.print(text, contentType);
        if (!archived && text.startsWith("ERROR ")) {
          ApplicationManager.getApplication().invokeLater(new Runnable() {
            @Override
            public void run() {
View Full Code Here

    myStatusView.attachToServer(server);
    myConsoleView.clear();
    server.addOutputListener(new JstdServerOutputListener() {
      @Override
      public void onOutputAvailable(@NotNull String text, @NotNull Key outputType) {
        ConsoleViewContentType contentType = ConsoleViewContentType.getConsoleViewType(outputType);
        myConsoleView.print(text, contentType);
      }

      @Override
      public void onEvent(@NotNull JsonObject obj) {}
View Full Code Here

      }
    });
  }

  private static ConsoleViewContentType getOutputAttributes(String userName) {
    return new ConsoleViewContentType("UserName",
        new TextAttributes(getColor(userName), Color.white, Color.white, null, Font.BOLD)) {
    };
  }
View Full Code Here

  public BaseOutgoingLocalMessage(String messageText) {
    super(messageText, new Date());
  }

  protected ConsoleViewContentType getTextAttributes() {
    return new ConsoleViewContentType("SelfText",
        new TextAttributes(new JBColor(Gray._100, Gray._140), UIUtil.getListBackground(), UIUtil.getListBackground(), null, Font.PLAIN)) {
    };
  }
View Full Code Here

        final JavaREPLLanguageConsole console = languageConsoleView.getConsole();
        for (String statement : statements) {
            final String st = statement + "\n";

            final ConsoleViewContentType outputType = ConsoleViewContentType.NORMAL_OUTPUT;
            JavaREPLLanguageConsole.printToConsole(console, st, outputType, null);

            final JavaREPLConsoleExecuteActionHandler actionHandler = consoleExecuteActionHandler;
            actionHandler.processLine(st);
        }
View Full Code Here

   * Print highlighted output to the console
   * @param console
   * @param text
   */
  public static void processOutput(LanguageConsoleImpl console, String text, Key attributes) {
    final ConsoleViewContentType outputType = ConsoleViewContentType.NORMAL_OUTPUT;
    // todo implement multiple cases for error etc.
    final ConsoleViewImpl consoleView = console.getHistoryViewer().getUserData(ConsoleViewImpl.CONSOLE_VIEW_IN_EDITOR_VIEW);
    if (consoleView != null) {
      consoleView.print(text, outputType);
    }
View Full Code Here

TOP

Related Classes of com.intellij.execution.ui.ConsoleViewContentType

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.