Sha256: 8c648caf4e0eda6de5affe28dd05bbfd8fe7d2d54a91870fe4867153917deb0d
Contents?: true
Size: 1.16 KB
Versions: 1
Compression:
Stored size: 1.16 KB
Contents
# Copyright (C) 2010, 2011 Rocky Bernstein <rockyb@rubyforge.net> # I/O related command processor methods require_relative '../app/util' class Trepan class CmdProcessor def errmsg(message, opts={}) message = safe_rep(message) unless opts[:unlimited] if @settings[:highlight] && defined?(Term::ANSIColor) message = Term::ANSIColor.italic + message + Term::ANSIColor.reset end @dbgr.intf[-1].errmsg(message) end def msg(message, opts={}) message = safe_rep(message) unless opts[:unlimited] @dbgr.intf[-1].msg(message) end def msg_nocr(message, opts={}) message = safe_rep(message) unless opts[:unlimited] @dbgr.intf[-1].msg_nocr(message) end def read_command() @dbgr.intf[-1].read_command(@prompt) end def safe_rep(str) Util::safe_repr(str, @settings[:maxstring]) end def section(message, opts={}) message = safe_rep(message) unless opts[:unlimited] if @settings[:highlight] && defined?(Term::ANSIColor) message = Term::ANSIColor.bold + message + Term::ANSIColor.reset end @dbgr.intf[-1].msg(message) end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
trepanning-0.1.0 | processor/msg.rb |