Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 5 of 5 for GetTerminalWidth (0.1 sec)

  1. api/maven-api-core/src/main/java/org/apache/maven/api/services/MessageBuilderFactory.java

         */
        boolean isColorEnabled();
    
        /**
         * Returns the terminal width or <code>-1</code> if not supported.
         * @return the terminal width
         */
        int getTerminalWidth();
    
        /**
         * Creates a new message builder.
         * @return a new message builder
         */
        @Nonnull
        MessageBuilder builder();
    
        /**
    Registered: Sun Nov 03 03:35:11 UTC 2024
    - Last Modified: Mon Jan 08 10:37:09 UTC 2024
    - 1.8K bytes
    - Viewed (0)
  2. cmd/update-notifier.go

    	maxContentWidth := max(line1Length, line2Length)
    
    	// termWidth is set to a default one to use when we are
    	// not able to calculate terminal width via OS syscalls
    	termWidth := 25
    	if width, err := pb.GetTerminalWidth(); err == nil {
    		termWidth = width
    	}
    
    	// Box cannot be printed if terminal width is small than maxContentWidth
    	if maxContentWidth > termWidth {
    		return "\n" + line1InColor + "\n" + line2InColor + "\n\n"
    	}
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Sat Mar 09 03:07:08 UTC 2024
    - 3.6K bytes
    - Viewed (0)
  3. compat/maven-embedder/src/main/java/org/apache/maven/cli/event/ExecutionEventLogger.java

        }
    
        private void init() {
            if (maxProjectNameLength == 0) {
                if (terminalWidth < 0) {
                    terminalWidth = messageBuilderFactory.getTerminalWidth();
                }
                terminalWidth = Math.min(
                        MAX_TERMINAL_WIDTH,
                        Math.max(terminalWidth <= 0 ? DEFAULT_TERMINAL_WIDTH : terminalWidth, MIN_TERMINAL_WIDTH));
    Registered: Sun Nov 03 03:35:11 UTC 2024
    - Last Modified: Fri Oct 25 12:31:46 UTC 2024
    - 17.2K bytes
    - Viewed (0)
  4. impl/maven-cli/src/main/java/org/apache/maven/cling/invoker/CommonsCliOptions.java

            }
    
            public void displayHelp(String command, Consumer<String> pw) {
                HelpFormatter formatter = new HelpFormatter();
    
                int width = MessageUtils.getTerminalWidth();
                if (width <= 0) {
                    width = HelpFormatter.DEFAULT_WIDTH;
                }
    
                pw.accept("");
    
                StringWriter sw = new StringWriter();
    Registered: Sun Nov 03 03:35:11 UTC 2024
    - Last Modified: Fri Oct 25 12:31:46 UTC 2024
    - 18.5K bytes
    - Viewed (0)
  5. compat/maven-embedder/src/main/java/org/apache/maven/cli/CLIManager.java

            displayHelp(new PrintWriter(stdout));
        }
    
        public void displayHelp(PrintWriter pw) {
            HelpFormatter formatter = new HelpFormatter();
    
            int width = MessageUtils.getTerminalWidth();
            if (width <= 0) {
                width = HelpFormatter.DEFAULT_WIDTH;
            }
    
            pw.println();
    
            formatter.printHelp(
                    pw,
                    width,
    Registered: Sun Nov 03 03:35:11 UTC 2024
    - Last Modified: Fri Oct 25 12:31:46 UTC 2024
    - 17.6K bytes
    - Viewed (0)
Back to top