[SOLVED] Escape sequences instead of colors in rxvt-unicode

On a Git cheat sheet I found that I could add nice colors to Git's output, so I edited my ~/.gitconfig by adding:
[color]
ui = auto
[color "branch"]
current = yellow reverse
local = yellow
remote = green
[color "diff"]
meta = yellow bold
frag = magenta bold
old = red bold
new = green bold
[color "status"]
added = yellow
changed = green
untracked = cyan
However, when performing a git log my terminal looks like this:
ESC[33mcommit 226dcb52565b58952b78fb107d8d9def3ca396abESC[m
Merge: 8f8af9f 93341d8
where ESC's colors are reversed. So, instead of yellow commit lines it outputs everything in plain text.
What's wrong with my configuration? I am using rxvt-unicode 9.15-3.
Last edited by Marcel- (2012-12-06 13:14:12)

Someone on the mailing list said that this was due to incorrect parameters to my pager, less. Adding -R to $LESS (or deleting the variable entirely) solved this issue.

Similar Messages

  • Escape Sequences for HP Color LaserJet 3600n

    I want to be able to print a file to my 3600n printer with certain text printed in color. I print from a Fedora14 box. For output to the screen, I can use the well-known VT100 terminal escape sequences to achieve colored display, in, say, red. I want to achieve the same effect with printed files.
    Does the 3600n respond to escape sequences? If so, where can I find a list of these escape sequences?
    TIA,
      Jon

    This seems to be a commercial product. For the best chance at finding a solution I would suggest posting in the forum for HP Business Support!
    You can find the Commercial Laserjet board here:
    http://h30499.www3.hp.com/t5/Printers-LaserJet/bd-p/bsc-413
    Best of Luck!
    You can say thanks by clicking the Kudos Star in my post. If my post resolves your problem, please mark it as Accepted Solution so others can benefit too.

  • [SOLVED] Highlighted text in the shell, appearance rxvt-unicode

    Hi,
    Short question, when I highlight text in the shell or when text get highlighted in ncmpcpp or outer app running in the shell it gets basically impossible to read. Because background to text get the same color and strength then the text.
    what setting should I look for to change what it look like when I mark and highlight text in the shell?
    Thank you!
    All the best,
    Christer
    Last edited by agkbill (2012-10-13 20:41:41)

    Additional info.
    I am using i3 as window manager and  terminal emulator "rxvt-unicode-256color"
    .xinitrc
    # set the cursor
    xsetroot -cursor_name left_ptr
    # set German keyboard layout
    # setxkbmap -layout de
    # start xmonad
    #Power management turn off monitor etc
    #xset dpms 0 7200 10800 &
    xset -dpms; xset s off
    # xloadimage laddar bakgrundsbild fick det inte att fungera tillsamans med xcompmgr som man
    # använder för att få genomskinliga terminal fönster mm. Ersätter med bildvisaren "feh"
    #xloadimage -onroot -fullscreen /home/christer/devices-extern/windows7/archlinux/stone_wall_ce.png
    xrdb -merge ~/.Xresources # Denna rad behövs ifall man vill använda TERMINAL/emulator "urxvt"
    feh --bg-scale /home/christer/devices-extern/windows7/archlinux/stone_wall_ce.png
    setxkbmap -layout "us, se" -option "grp:alt_shift_toggle" #alt"grp:caps_toggle"
    xcompmgr -c &
    #xmonad
    #awesome
    exec /usr/bin/i3 -V -d all >~/i3log/i3log-$(date +'%F-%k-%M-%S') 2>&1
    .Xresources
    # transparency - true or false (default)
    #URxvt*transparent: true
    # tint with any color; i.e., blue, red, tomato4, olivedrab2, etc.
    # some nice listings are at:
    # http://www.nisrv.com/drupal/?q=node/11
    # http://www.htmlgoodies.com/tutorials/colors/article.php/3478921
    URxvt*tintColor: white
    URxvt*inheritPixmap: true
    # shading - 0 to 99 darkens, 101 to 200 lightens.
    # Don't use with tintColor; just use a darker or lighter color instead.
    #URxvt*shading: 40
    # scrollback buffer lines - 65535 is max on most machines (64 is default)
    URxvt*saveLines: 12000
    # font color (default is black)
    URxvt*foreground: DarkSlateGray1
    # background color (prior to tinting) (default is white)
    URxvt.depth: 32
    URxvt.background: [10]#black
    # Xft (X FreeType) with Bitstream, DejaVu, Liberation, or Terminus fonts:
    # Fedora/debian packages: libXft/libxft2
    # An anti-aliased font setup with Xft looks fantastic; it can be a bit choppy
    # on older systems. You can always turn off anti-aliasing (antialias=false) if
    # your terminal is sluggish. Use only ONE of the Xft pairs below:
    # Xft: Bitstream fonts
    # Fedora/debian packages: bitstream-vera-sans-mono-fonts/ttf-bitstream-vera
    #URxvt*font: xft:Bitstream Vera Sans Mono:pixelsize=12:antialias=true:hinting=true
    #URxvt*boldFont: xft:Bitstream Vera Sans Mono:bold:pixelsize=12:antialias=true:hinting=true
    # Xft: DejaVu fonts
    # Fedora/debian packages: dejavu-sans-mono-fonts/ttf-dejavu
    URxvt*font: xft:DejaVu Sans Mono:pixelsize=12:antialias=true:hinting=true
    URxvt*boldFont: xft:DejaVu Sans Mono:bold:pixelsize=12:antialias=true:hinting=true
    # Xft: Liberation fonts
    # Fedora/debian packages: liberation-mono-fonts/ttf-liberation
    #URxvt*font: xft:Liberation Mono:pixelsize=13:antialias=true:hinting=true
    #URxvt*boldFont: xft:Liberation Mono:bold:pixelsize=13:antialias=true:hinting=true
    # Xft: Terminus fonts
    # Fedora/debian packages: terminus-fonts/xfonts-terminus
    #URxvt*font: xft:terminus:pixelsize=15
    #URxvt*boldFont: xft:terminus:bold:pixelsize=15
    # Traditional fonts - a more traditional font setup in lieu of xft
    #URxvt*font:-*-courier-medium-r-normal-*-14-*-*-*-*-*-iso8859-1
    #URxvt*boldFont:-*-courier-bold-r-normal-*-14-*-*-*-*-*-iso8859-1
    # Replace blue folder colors with a lighter shade for clarity. To
    # set colored folders and files within urxvt, xterm, and aterm, add
    # the following line to your ~/.bashrc ($HOME/.bashrc) file under
    # the heading "# User specific aliases and functions":
    # alias ls="ls -h --color=auto"
    URxvt*color4: RoyalBlue
    URxvt*color12: RoyalBlue
    # scrollbar - true (default) or false
    URxvt*scrollBar: false
    # scrollbar position - left=false (default) or right=true
    URxvt*scrollBar_right: false
    # scrollbar style - rxvt (default), plain, next, or xterm
    URxvt*scrollstyle: plain
    #Fade the text by the given percentage when focus is lost.
    URxvt*enable-fading on
    URxvt*fade 50
    URxvt*fadecolor black
    Biggest problem is when I running console based applications like ncmpcpp or ranger.
    Last edited by agkbill (2012-10-13 08:34:28)

  • [Solved] no non-ASCII character input in rxvt-unicode

    Hello everyone,
    For some days now, I can't write any non-ASCII characters any more in rxvt-unicode and rxvt-unicode-patched. Unfortunately, downgrading the rxvt-unicode package doesn't seem to help. To have at least a temporary solution, I'd like to know at least which packages I could try to downgrade as well. Any ideas, anyone?
    greez,
    maxmin
    Last edited by Maximalminimalist (2011-03-12 13:12:26)

    When I try to type a non-ASCII-character I get nothing at all. This happens with my custom keyboard layout (modified programmer dvorak) and in some layouts I already tried (us: altgr-intl, ch, de and fr)
    When I paste a non-ASCII characters in rxvt-unicode I get
    maxmin ~ $ ?
    This happens only on my x86_64 desktop which is more up to date than my i686 laptop. (I'm afraid now to do any updates.)
    EDIT: I'm sorry, I don't know what you mean with locale settings. What do you mean with that?
    EDIT2: Maybe just typing locale in the terminal is what you mean:
    maxmin ~ $ locale
    locale: Cannot set LC_CTYPE to default locale: No such file or directory
    locale: Cannot set LC_MESSAGES to default locale: No such file or directory
    locale: Cannot set LC_ALL to default locale: No such file or directory
    LANG=en_US.utf8
    LC_CTYPE="en_US.utf8"
    LC_NUMERIC="en_US.utf8"
    LC_TIME="en_US.utf8"
    LC_COLLATE="en_US.utf8"
    LC_MONETARY="en_US.utf8"
    LC_MESSAGES="en_US.utf8"
    LC_PAPER="en_US.utf8"
    LC_NAME="en_US.utf8"
    LC_ADDRESS="en_US.utf8"
    LC_TELEPHONE="en_US.utf8"
    LC_MEASUREMENT="en_US.utf8"
    LC_IDENTIFICATION="en_US.utf8"
    LC_ALL=
    With other terminal emulators I get sometimes also nothing and sometimes right displayed but wrong interpreted character in vim. I didn't take notes while doing that but I'll try again if needed.
    Last edited by Maximalminimalist (2011-03-06 21:51:23)

  • [SOLVED] rxvt-unicode font color too dark

    I just updated rxvt-unicode-patched and now my font is quite dark. It was bright previously but now appears as:
    Here is my .bashrc:
    Xcursor.theme: Obsidian
    URxvt*scrollBar: false
    URxvt*geometry: 120x70
    URxvt*depth: 32
    URxvt*jumpScroll: true
    URxvt*skipScroll: true
    URxvt*visualBell: false
    URxvt*buffered: true
    URxvt*background: rgba:0000/0000/0000/6666
    URxvt*foreground: rgba:aaaa/aaaa/aaaa/7777
    URxvt*transparent: false
    URxvt*fading: 10
    URxvt*fadeColor: grey
    URxvt*shading: 75
    URxvt*font: xft:Terminus-12
    URxvt*boldFont: xft:Terminus-12-bold
    URxvt*urlLauncher: google-chrome
    URxvt.matcher.button: 2
    URxvt.perl-ext-common: matcher,clipboard
    URxvt.perl-lib: /usr/lib/urxvt/perl/matcher
    URxvt*intensityStyles: true
    URxvt*internalBorder: 0
    URxvt*externalBorder: 1
    URxvt*borderLess: false
    URxvt*termName: rxvt-unicode
    urxvt.colorBD: #ffffff
    urxvt.colorIT: #bbbbbb
    urxvt.colorUL: #999999
    urxvt.underlineColor: #999999
    XTerm*Geometry: 100x60
    XTerm*background: Black
    XTerm*foreground: White
    XTerm*scrollBar: false
    XTerm*termName: xterm-256color
    !*background: #121212
    !black
    !*color0: #353535
    !*color8: #666666
    !red
    !*color1: #AE4747
    !*color9: #EE6363
    !green
    !*color2: #556B2F
    !*color10: #9ACD32
    !brown/yellow
    !*color3: #DAA520
    !*color11: #FFC125
    !blue
    !*color4: #6F99B4
    !*color12: #7C96B0
    !magenta
    !*color5: #8B7B8B
    !*color13: #D8BFD8
    !cyan
    !*color6: #A7A15E
    !*color14: #F0E68C
    !white
    !*color7: #DDDDDD
    !*color15: #FFFFFF
    !*foreground: #DDDDDD
    *background: #151515
    *foreground: #ffffff
    !black
    *color0: #111111
    *color8: #505050
    !red
    *color1: #b04020
    *color9: #dd4010
    !green
    *color2: #afd700
    *color10: #daff30
    !yellow
    *color3: #f7cf0a
    !*color11: #fce70d
    *color11: #ff9600
    !blue
    *color4: #3060aa
    *color12: #6099dd
    !magenta
    *color5: #d6156c
    *color13: #fe4365
    !cyan
    *color6: #a0c2de
    *color14: #c9dee8
    !white
    *color7: #cacaca
    *color15: #b0b0b0
    (changing the last two lines to FFFFFF makes no difference)
    BLACK="\e[0;30m"
    BLUE="\e[0;34m"
    GREEN="\e[0;32m"
    CYAN="\e[0;36m"
    RED="\e[0;31m"
    PURPLE="\e[0;35m"
    BROWN="\e[0;33m"
    LIGHTGRAY="\e[0;38m"
    DARKGRAY="\e[1;30m"
    LIGHTBLUE="\e[1;34m"
    LIGHTGREEN="\e[1;32m"
    LIGHTCYAN="\e[1;36m"
    LIGHTRED="\e[1;31m"
    LIGHTPURPLE="\e[1;35m"
    YELLOW="\e[1;33m"
    WHITE="\e[1;37m"
    NC="\e[0m" # No Color
    PS1="\[$BLUE\]ââ\[$PURPLE\][ \[$YELLOW\]\$(date +%D) $(date +%r) \[$PURPLE\]][ \[$LIGHTGREEN\]\w \[$PURPLE\]]\n\[$BLUE\]ââ\[$YELLOW\]> \[$LIGHTGRAY\]"
    ^^ When on the PS1 line there I change the end from LIGHTGRAY to WHITE, only the first couple lines appear white sometimes, others it appears as it should:
    Appreciate any help, thanks
    Last edited by colbert (2011-07-05 03:04:36)

    URxvt*foreground: rgba:aaaa/aaaa/aaaa/7777
    I think this is your font color. Have you tried changing it?
    XTerm*foreground: White
    This one is for xterm so no wonder it doesn't do anything in urxvt.
    Edit: Setting
    urxvt.foreground: #aaaaaa
    does produce dark font, '#ffffff' gets me bright white, as expected.
    Last edited by karol (2011-07-04 23:32:06)

  • [SOLVED] Bash changes consolle's colors by itself

    Hi archers,
    I've wrote a little script which ask for the result of a given random moltiplication because I was exercising with $RANDOM and something strange's happend.
    No matter where I am (Tty, Tmux, Urxvt, Xterm...) Bash changes consolle's colors by itself if I do ^c to stop the script, instead of write a reply.
    i.e.'s:
    correct behaviour
    $ 8 * 9 = ?
    $ 72
    $ ls
    file in red file in yellow file in grey...
    Wrong behaviour
    $ 8 *9 = ?
    $ ^c
    $ ls
    file in blue file in green file in white...
    What the heck?
    Bash version is 4.2.39(2)-release.
    The script is the following:
    while :
    do
    min="3"
    max="7"
    fat1="$(($RANDOM%$max+$min))"
    fat2="$(($RANDOM%$max+$min))"
    prod="$(($fat1*$fat2))"
    echo "$fat1 * $fat2 = ?"
    read res
    while [ "$res" != "$prod" ]
    do
    echo "$prod"
    echo "Insert the correct result."
    tavPit
    done
    return 0
    done
    Everything is up to date.
    .bashrc
    [[ $- != *i* ]] && return
    complete -cf sudo
    [ -f /etc/bash_completion ] && ! shopt -oq posix && . /etc/bash_completion
    [ -f ~/.bash/include ] && . ~/.bash/include
    [ -e "$HOME"/.dircolors ] && eval $(dircolors -b "$HOME"/.dircolors)
    include
    #!/bin/bash
    [ -f ~/.bash/alias ] && . ~/.bash/alias
    [ -f ~/.bash/color ] && . ~/.bash/color
    [ -f ~/.bash/export ] && . ~/.bash/export
    [ -f ~/.bash/shopt ] && . ~/.bash/shopt
    [ -f ~/.bash/stty ] && . ~/.bash/stty
    [ -f ~/.bash/set ] && . ~/.bash/set
    color
    nc="\e[0m"
    nbk="\e[0;30m"
    nre="\e[0;31m"
    ngr="\e[0;32m"
    nye="\e[0;33m"
    nbl="\e[0;34m"
    nma="\e[0;35m"
    ncy="\e[0;36m"
    nwh="\e[0;37m"
    bbk="\e[1;30m"
    bre="\e[1;31m"
    bgr="\e[1;32m"
    bye="\e[1;33m"
    bbl="\e[1;34m"
    bma="\e[1;35m"
    bcy="\e[1;36m"
    bwh="\e[1;37m"
    end="\[\e[m\]"
    man() {
    env \
    LESS_TERMCAP_mb=$(printf "\e[0;32m") \
    LESS_TERMCAP_md=$(printf "\e[0;32m") \
    LESS_TERMCAP_me=$(printf "\e[0m") \
    LESS_TERMCAP_se=$(printf "\e[0m") \
    LESS_TERMCAP_so=$(printf "\e[1;31m") \
    LESS_TERMCAP_ue=$(printf "\e[0m") \
    LESS_TERMCAP_us=$(printf "\e[1;33m") \
    man "${@}"
    if [ "$TERM" = "linux" ]; then
    echo -en "\e]P0000000" # Black.
    echo -en "\e]P9ff0000" # Red.
    echo -en "\e]PA00ff00" # Green.
    echo -en "\e]PBffff00" # Yellow.
    echo -en "\e]PC2b4f98" # Blue.
    echo -en "\e]PDff00ff" # Magenta.
    echo -en "\e]PE00ffff" # Cyan.
    echo -en "\e]PFffffff" # White.
    clear
    fi
    .dircolors
    TERM linux
    TERM linux+utf8
    TERM rxvt-unicode
    TERM rxvt-unicode-256color
    TERM screen
    TERM screen-256color
    TERM xterm
    TERM putty
    EIGHTBIT 1
    NORMAL 01;30
    FILE 01;30
    DIR 31
    LINK 36
    FIFO 03;33
    SOCK 03;33
    DOOR 32
    BLK 32
    CHR 32
    ORPHAN 05;33
    EXEC 33
    .tar 31
    .tgz 31
    .arj 31
    .taz 31
    .lzh 31
    .zip 31
    .7z 31
    .z 31
    .Z 31
    .gz 31
    .bz2 31
    .deb 31
    .rpm 31
    .jar 31
    .rar 31
    .xz 31
    .jpg 35
    .jpeg 35
    .gif 35
    .bmp 35
    .pbm 35
    .pgm 35
    .ppm 35
    .tga 35
    .xbm 35
    .xpm 35
    .tif 35
    .tiff 35
    .png 35
    .fli 35
    .gl 35
    .dl 35
    .xcf 35
    .xwd 35
    .pdf 35
    .ogg 34
    .mp3 34
    .wav 34
    .mov 34
    .mpg 34
    .mpeg 34
    .asf 34
    .avi 34
    .mkv 34
    .wmv 34
    .ogm 34
    .C 37
    .H 37
    .c 37
    .h 37
    .cxx 37
    .hxx 37
    .cpp 37
    .hpp 37
    .py 37
    .sh 37
    .vim 37
    .o 37
    .so 37
    .a 37
    .ko 37
    .rc 36
    *rc 36
    Thanks a lot.
    Last edited by rix (2012-11-26 15:38:28)

    Bandit Bowman wrote:My colours are unaffected after running the function. [...]
    Here colors change when I send SIGINT to a running instance of my script; as said before.
    Bandit Bowman wrote:[...] What does $LS_COLORS look like before and after? [...]
    When everything is working right:
    $ echo $LS_COLORS
    $ no=01;30:fi=01;30:di=31:ln=36:pi=03;33:so=03;33:do=32:bd=32:cd=32:or=05;33:ex=33:
    *.tar=31:*.tgz=31:*.arj=31:*.taz=31:*.lzh=31:*.zip=31:*.7z=31:*.z=31:*.Z=31:*.gz=31:
    *.bz2=31:*.deb=31:*.rpm=31:*.jar=31:*.rar=31:*.xz=31:*.jpg=35:*.jpeg=35:*.gif=35:
    *.bmp=35:*.pbm=35:*.pgm=35:*.ppm=35:*.tga=35:*.xbm=35:*.xpm=35:*.tif=35:*.tiff=35:
    *.png=35:*.fli=35:*.gl=35:*.dl=35:*.xcf=35:*.xwd=35:*.pdf=35:*.ogg=34:*.mp3=34:
    *.wav=34:*.mov=34:*.mpg=34:*.mpeg=34:*.asf=34:*.avi=34:*.mkv=34:*.wmv=34:*.ogm=34:
    *.C=37:*.H=37:*.c=37:*.h=37:*.cxx=37:*.hxx=37:*.cpp=37:*.hpp=37:*.py=37:*.sh=37:
    *.vim=37:*.o=37:*.so=37:*.a=37:*.ko=37:*.rc=36:*rc=36:
    When texts change color (the strange behaviour):
    $ echo $LS_COLORS
    $
    Bandit Bowman wrote:[...] Is this the whole script or just a snippet [...]
    Whole.
    Bandit Bowman wrote:[...] because I don't see anything that should modify it. [...]
    That's why I'm asking.
    Bandit Bowman wrote:[...] here's a slightly more straightforward version [...]
    Thanks, I've learnt something.
    Bandit Bowman wrote:[...] although it won't help with the colours.
    Thanks for the reply anyway.
    Bandit Bowman wrote:[...] English: [...]
    Also, many thanks again.
    Edit: solved. "$LS_COLORS" must be set if you want colors.
    Last edited by rix (2012-11-26 15:38:06)

  • Leopard Terminal.app no longer supports ANSI print escape sequences?!!

    I print my email using pine's "attached-to-ansi" option, which used to work great in Tiger with Terminal.app. It no longer works in Leopard. It also breaks things like the "ansiprt" Unix command.
    This is a start/stop escape sequence that diverts text between the start/stop sequences to the printer. See http://www.termsys.demon.co.uk/vtansi.htm as a reference.
    Is there some Terminal.app setting I need to use to enable this? Some specific terminal type perhaps?
    Suggesting that I use enscript or other techniques don't work, as I use the Terminal to ssh into my mail server, then run pine on the mail server.
    Anyway, any idea how to get this very desirable feature back?
    Thanks,
    -John

    HI,
    I tried to set "Escape non-ASCII input" without any change. I didn't see an option to change "Escape non-ASCII output". I tried a few other things without success either using a different terminal type and so forth. I looked in the .term file and didn't see anything text related to ANSI or ASCII or escape.
    If I change a Terminal preference do I need to quit and restart Terminal to test the change, or does the change take place as soon as I change it in the menu? I tried quitting and restarting after checking "Escape non-ASCII input" and when I restart the box was unchecked. I couldn't find a "save preferences option either.
    In Tiger, my terminal type was xterm-color- same in Leopard. I had checked off "Escape non-ASCII characters" under Tiger.
    Here's exactly what I do, *which used to work in Leopard*.
    I run Terminal.app on my MacBook, and ssh to a mail server. On the mail server, I run the pine command to read my mail. Pine has an option to print email using ASCII escape sequences. Terminal.app sees these escape sequences and diverts the text to the default printer on my MacBook.
    Under Leopard, the Terminal doesn't catch the ANSI escape code, and just spews the text to the terminal window. Nothing has changed on the mail server side. I;m using the sane ssh command.
    Enscript won't work, as the printer connected to the mail server is often as not in a different state than my MacBook.
    Not all terminal emulators support the ANSI print escape sequences. Terminal didn't before Tiger, if I remember correctly. I used to use a very nice terminal emulator called Data Comet which did it.
    ANSI printing used to be a fairly common way to print to a local printer connected to via a parallel cable. Besides pine, the Unix command ansiprt http://kb.iu.edu/data/abye.html could be used to print remote files on the local printer. Some terminal emulator programs used the idea to hook the ANSI escape sequence to the printing system, extending the functionality to use any printer accessible by the local system.
    Thanks again for all your help. I hope I've clarified what I'm trying to do.
    -John

  • XML escape sequences for brackets and xmltype.extract

    G'day gang, I'm hoping somebody would be kind enough to help me with the following query please.
    I have a web service that is returning the following XML stream into an XMLType in the database:
    <OutOfStockAdviceResponse xmlns="http://abc.org/abcWebServices">
      <OutOfStockAdviceResult>
      & lt;Response& lt;ResponseCode& gt;0& lt;/ResponseCode& gt;
      & lt;ResponseMessage& gt;Successful& lt;/ResponseMessage& gt;
      & lt;/Response& gt;
      </OutOfStockAdviceResult>
    </OutOfStockAdviceeResponse>You'll note the & lt; and & gt; characters (note to display these strings in OTN I've had to add a space between the & and the lt; or gt;. The spaces don't actually occur in the real XML data coming back).
    What's odd about this XML stream coming back is it is mixing the use of the XML angle brackets with the escape character equivalents (eg. & lt; and & gt;) half way through the XML stream. Is this valid for an XML stream to do this? Any idea what would cause this? Is it possible the source is creating 2 separate XML streams using different character sets and then concatenating them to get this result?
    The reason I'm asking is I'm attempting via PL/SQL to extract the ResponseCode and ResponseMessage tags with the following code:
      v_response_code := XMLType.extract(v_response,
          '/OutOfStockAdviceResponse/OutOfStockAdviceResult/Response/ResponseCode/text()',
          'xmlns="http://abc.org/abcWebServices"').getnumberval;
      v_response_msg  := XMLType.extract(v_response,
          '/OutOfStockAdviceResponse/OutOfStockAdviceResult/Response/ResponseMessage/text()',
          'xmlns="http://abc.org/abcWebServices"').getstringval;Both calls are failing with:
    ORA-30625: method dispatch on NULL SELF argument is disallowedCan anybody point me in the right direction for solving this issue? Is there a way to get the xmltype.extract function to recognize the different character encoding schemes (if they do indeed actually exist)?
    Any help appreciated.
    CM.
    PS. Apologize for the weak subject line.

    Chris
    Since that Serviceis actually returning the escaped representation of '<' and '>' inside OutOfStocAdviceResult, the XML Parser considers that whole block of text to be simply a text node child the parent element, not valid XML. Hence the result of your XPath expressions is null and you get the ORA-30625 when you try to invoke the getNumberVal() and getStringVal() methods, which is the PL/SQL equivilant of a Java Null Pointer Exception.
    You can solve it as follows...
    set define off
    set serveroutput on
    declare
      v_response xmltype;
      v_response_code number(4);
      v_response_msg varchar2(64);
      v_xmltext varchar2(256);
      v_OutOfStockResponse xmltype := xmltype(
    '<OutOfStockAdviceResponse xmlns="http://abc.org/abcWebServices"> 
      <OutOfStockAdviceResult>
        & lt;Response& gt;& lt;ResponseCode& gt;0& lt;/ResponseCode& gt;& lt;ResponseMessage& gt;Successful& lt;/ResponseMessage& gt;& lt;/Response& gt; 
      </OutOfStockAdviceResult>
    </OutOfStockAdviceResponse>');
    begin
      select extractValue(v_OutOfStockResponse,'/OutOfStockAdviceResponse/OutOfStockAdviceResult','xmlns="http://abc.org/abcWebServices"')
        into v_xmltext
        from dual;
       dbms_output.put_line('Text = ' || v_xmlText);
       v_response := xmltype(v_xmltext);
       v_response_code := v_response.extract('/Response/ResponseCode/text()').getnumberval();
       v_response_msg  := v_response.extract('/Response/ResponseMessage/text()').getstringval();
       dbms_output.put_line('Code = ' || v_response_code);
       dbms_output.put_line('Msg = ' || v_response_msg);
    end;Note that like you I had to insert space characters between in the 'lt' and 'gt' escape sequences...
    When this is run you get the following
    SQL> set define off
    SQL> set serveroutput on
    SQL> --
    SQL> declare
      2    v_response xmltype;
      3    v_response_code number(4);
      4    v_response_msg varchar2(64);
      5    v_xmltext varchar2(256);
      6    v_OutOfStockResponse xmltype := xmltype(
      7  '<OutOfStockAdviceResponse xmlns="http://abc.org/abcWebServices">
      8    <OutOfStockAdviceResult>
      9      & lt;Response& gt;& lt;ResponseCode& gt;0& lt;/ResponseCode& gt;& lt;ResponseMessage& gt;Successful& lt;/ResponseMessage& gt;& lt;/Response& gt;
    10    </OutOfStockAdviceResult>
    11  </OutOfStockAdviceResponse>');
    12  begin
    13    select extractValue(v_OutOfStockResponse,'/OutOfStockAdviceResponse/OutOfStockAdviceResult','xmlns="http://abc.org/abcWebServices"')
    14      into v_xmltext
    15      from dual;
    16     dbms_output.put_line('Text = ' || v_xmlText);
    17     v_response := xmltype(v_xmltext);
    18     v_response_code := v_response.extract('/Response/ResponseCode/text()').getnumberval();
    19     v_response_msg  := v_response.extract('/Response/ResponseMessage/text()').getstringval();
    20     dbms_output.put_line('Code = ' || v_response_code);
    21     dbms_output.put_line('Msg = ' || v_response_msg);
    22  end;
    23  /
    Text =
    <Response><ResponseCode>0</ResponseCode><ResponseMessage>Successful</ResponseMes
    sage></Response>
    Code = 0
    Msg = Successful
    PL/SQL procedure successfully completed.
    SQL>Basically we extract the encoded text using extractValue() which will de-escape the escapted characters and then create a new XMLType which we can operate on

  • Escape Sequences don't work with tcsh

    Is it a known issue that escape sequences don't work on tcsh build for MacOS X?
    mtennes@judah:/Users/mtennes>>tcsh --version
    tcsh 6.12.00 (Astron) 2002-07-23 (powerpc-apple-darwin) options 8b,nls,dl,al,kan,sm,rh,color,dspm,filec
    mtennes@judah:/Users/mtennes>>echo -n "\033]0;${USER}@${HOST}:$cwd\007"
    \033]0;mtennes@:/Users/mtennes\007mtennes@judah:/Users/mtennes>>
    mtennes@judah:/Users/mtennes>>/usr/local/bin/tcsh --version
    tcsh 6.14.00 (Astron) 2005-03-25 (powerpc-apple-darwin) options wide,nls,dl,al,kan,rh,color,filec
    mtennes@judah:/Users/mtennes>>/usr/local/bin/tcsh
    mtennes@judah:/Users/mtennes>>echo -n "\033]0;${USER}@${HOST}:$cwd\007"
    \033]0;mtennes@:/Users/mtennes\007mtennes@judah:/Users/mtennes>>ssh atlantis
    mtennes@atlantis's password:
    Last login: Tue Mar 14 12:44:57 2006 from host.mydomain.com
    mtennes@atlantis:/home/00/mtennes>>tcsh --version
    tcsh 6.13.00 (Astron) 2004-05-19 (i386-intel-linux) options 8b,nls,dl,al,kan,rh,color,dspm,filec
    mtennes@atlantis:/home/00/mtennes>>echo -n "\033]0;${USER}@${HOST}:$cwd\007"
    mtennes@atlantis:/home/00/mtennes>>The above works an sets the title of the xterm
    PowerMac G5 2.7GHz DP   Mac OS X (10.4.5)  
    PowerMac G5 2.7GHz DP   Mac OS X (10.4.2)  
    PowerMac G5 2.7GHz DP   Mac OS X (10.4.2)  

    Hi Michael,
       I realize that this doesn't actually answer the question but why not just use the actual control characters? You can type them into the command line by typing the following:
    echo -n "<Control>-v<Escape>]0;${USER}@${HOST}:$cwd<Control>-v<Control>-g"
    which ends up looking like:
    echo -n "^[]0;${USER}@${HOST}:$cwd^G"
    where ^[ is the shell representation of the <ESC> control character and ^G is the shell representation of the <BEL> control character. Of course <Control>-v means holding down the control key while typing a 'v', <Escape> is the escape key and <Control>-g means holding down the control key while typing a 'g'. That actually works in any shell.
    Gary
    ~~~~
       I took a course in speed reading and was able to read War
       and Peace in twenty minutes.
       It's about Russia.
             -- Woody Allen

  • PCL Escape Sequence for PDF417 barcodes

    I have purchased the HP Laserjet Font Solutions (HP Part HG271US) for my HP Color LaserJet CP4020 Series printer so that I can create shipping labels with scannable barcodes for our customers.  I am able to generate the PCL code and print out code 39 and code 128 barcodes.  When I print out the PCL font list, it shows the escape sequences for the code 39 and code 128 barcodes.  I need to print out pdf417 barcodes as well but I don't get any escape sequences on the PCL font list or a font ID for the pdf417 barcode. 
    Does anyone know what the escape sequence is for the PDF417 barcode when using the HP Laserjet Font Solutions (HP Part HG271US)?

    A translation of your PCL snippet for Code 128:
    <Esc>&a0P Print Direction: 0 degree rotation
    <Esc>&a3R Cursor Position Vertical (row 3)
    <Esc>&a0C Cursor Position Horizontal (column 0)
    <Esc>(9Y Primary Font: Symbol Set (identifier = 9Y)
    <Esc>(s1P Primary Font: Spacing: Proportional
    <Esc>(s30V Primary Font: Height (30 points)
    <Esc>(s0S Primary Font: Style (Upright, solid)
    <Esc>(s0B Primary Font: Stroke Weight: Medium
    <Esc>(s28687T Primary Font: Typeface (identifier = 28687)
    *VttbRackLabelInfo.SupplierCode*
     Note that I've changed the "(s30v" to "(s30V" to comply with PCL syntax rules.
    And a translation of your PDF417 snippet:
    <Esc>&a0P Print Direction: 0 degree rotation
    <Esc>&a8R Cursor Position Vertical (row 8)
    <Esc>&a113C Cursor Position Horizontal (column 113)
    <Esc>(9Y Primary Font: Symbol Set (identifier = 9Y)
    <Esc>(s1P Primary Font: Spacing: Proportional
    <Esc>(s50V Primary Font: Height (50 points)
    <Esc>(s0S Primary Font: Style (Upright, solid)
    <Esc>(s0B Primary Font: Stroke Weight: Medium
    <Esc>(sp Primary Font: Spacing: Fixed
    b Primary Font: Stroke Weight: Medium
    24850T Primary Font: Typeface (identifier = 24850)
    *ttbRackLabelInfo.PCISegment15*
     with the same correction as above; note also that you have specified (the same) stroke weight twice, and two different spacing attributes (the latest will apply).
    It's possible that other values for some of these attributes may have non-standard interpretations by the font DIMM (e.g. to specifiy PDF417 error-correction level).

  • Print in text mode to detect escape sequences

    Hello,
    We have got an issu, on our .NET print program using Crystal 12 SP3. The issue has concequences on :
    - Barcode print on matrix printer
    - Barcode print on thermal printer
    - Other commands send to a FAX printer driver
    Using the SDK, the print driver receives print data in graphical print mode, but it has to be text mode for the printer driver to detect the correct escape sequences. The escapes sequences are used by the driver to switch the font or receive a command.
    Is there a way to force the print in text mode ?
    The same report printed from Crystal Reports 2008 SP 3 "works", but not from the .NET sdk.
    Here is a little example. We made a simple Report, containing 2 simple Text Objects :
    Code Barres $ [ /
    +$$;111;6;1;1;0;2 z +
    $$?0h0123456789$$?0/
    We redirected the print driver spool in a file. Here are the outputs :
    Printed from Crystal Report 2008 :
    [0;4 r+<[3;031w[3;032w[7s2CH
    x[1;2xF5-
    JÃ$Code Barres $ [ /
    J-$$$;111;6;1;1;0;2 z
    J$$$?0h0123456789$$?0/@[0;4 r
    Printed from .Net application using Crystal Report 2008 SDK :
    [0;4 r+<[3;031w[3;032w[7s2CH
    x
    JÅ$*'úø u20AC u20AC u20AC u20AC u20AC<|u201Au20ACu20ACu20ACu20ACu20ACu20ACu201A||u201Au20ACu20ACu20ACu20ACu20ACA@u201Aÿu20ACu20ACu20AC|u2019u20ACu20ACu20ACu20ACu20ACu20ACu2018r u20AC u20AC?ÿu20AC @u20AC @u20AC @u20AC @u20AC @u20AC @u20AC u20AC!u20AC u20AC u20AC u20AC u20AC!"ÿu20ACu20ACu20ACu20ACu20ACu20ACÿu20ACu20ACu20ACu20ACu20ACu20ACu20ACu20ACu20ACu20ACÿu20ACu20ACu20ACu20ACu20ACu20ACu20AC|u2019u20ACu20ACu20ACu20ACu20ACu20ACu2018ru20ACÁ! u20AC u20AC u20AC u20AC u20ACŽu201A u201A u0192ààu201A BBD8ÿð@@@`u20AC`u20AC0À
    J-*'7u201A u201A u0192ààu201A BBD8u201A u201A u0192ààu201A BBD8`àu2021u20ACu2021u201Eu20ACu20AC u20AC u20AC u20ACÿu20ACu20ACu20ACu20ACu20ACu20AC u20AC u20AC u20ACÿu20ACu20ACu20ACu20ACu20ACu20AC u20AC u20AC u20ACÿu20ACu20ACu20ACu20ACu20AC`àu2021u20ACu2021u201Eu20ACø>A u20ACu20AC!u20ACAu20ACAu20ACA@Ã@<`àu2021u20ACu2021u201Eu20ACu20AC u20AC u20AC u20ACÿu20ACu20ACu20ACu20ACu20AC`àu2021u20ACu2021u201Eu20ACu20AC u20AC u20AC u20ACÿu20ACu20ACu20ACu20ACu20AC`àu2021u20ACu2021u201Eu20ACü @u20AC@u20AC@u20AC ø`àu2021u20ACu2021u201Eu20ACu20ACu20AC u20AC@u20AC@u20AC@ u20AC@@u20AC@u20ACu20AC!u20ACu20ACu20ACu20ACu20ACu20ACu20AC u20AC@u20ACu20ACu20ACu20ACu20AC
    J*'Tu201A u201A u0192ààu201A BBD8u201A u201A u0192ààu201A BBD8  u20AC 1u20AC Au20AC Au20ACu20ACü @u20AC@u20AC@u20AC ø@u20AC@u20ACÿu20ACu20ACu20ACu20ACu20ACu20ACÿu20ACu20ACu20ACü @u20AC@u20AC@u20AC øu20AC u20AC u20AC u20ACÿu20ACu20ACu20ACu20ACu20ACu20ACu20AC u20AC@u20AC@u20AC@ u20AC@@u20AC@u20ACu20AC!u20ACu20AC u20AC@u20AC@u20ACu20AC@u20ACu20AC@u20ACu20AC!A#xu02C6<u20AC@u20AC@u20ACÿu20ACu20ACu20AC@Au20ACAu20ACAu20ACAu20ACAu0192|ø>A u20ACu20AC!u20ACAu20ACAu20ACA@Ã@<p@@@@@u20AC@8AÀNp>!A@u20ACu20AC@u20ACu20AC@u20ACu20AC@u20ACu20AC@u20ACu20AC!A>u20ACu20AC @u20AC@ u20AC@ u20AC@ u20AC@! Bu0152ðu201A u201A u0192ààu201A BBD8u201A u201A u0192ààu201A BBD8  u20AC 1u20AC Au20AC Au20ACu20ACü @u20AC@u20AC@u20AC ø`u20AC`u20AC0À@[0;4 r
    As you can see above, the characters contained in the report are sent "as this" in the print driver from Crystal Reports 2008. But the pixels represention of the characters are sent from the .Net SDK.

    Hello,
    thank you for your answer.
    I forgot to add the 2008 com+ API output, that is exactly the same as Crystal Report 2008.
    - From Crystal Reports 2008 : WORKS
    - From a program using the 2008 com+ Runtime API : WORKS
    - From a program using the 2008 .Net Runtime API : DON'T WORK
    You wrote that all the runtime print engine sends to the printer is essentially a picture. But It do send text using the com+ API.
    Should I understand : The .Net runtime print engine can't send text ?

  • Premiere Pro CC-MediaEncoder : Setting sequence composite linear color ?

    Hello, hello,
    Someone would tell me what is this option?
    Setting sequence> composite linear color (or GPU acceleration rendering quality max neccessary)?
    I wonder if the fact that my media encoder takes me 6 H encoding to make a video of 17mn which has no effect does not come from there?
    Since I do not know what is this option.
    Ahmotiond
    Bonjour, bonjour,
    Quelqu'un serait-il me dire à quoi sert cette option ?
    Reglage de sequence> composite en couleur linéaire (accéleration GPU ou qualité de rendu max, néccessaire) ??
    Je me demande si le fait que mon média encodeur me tape des 6 H d'encodage pour encoder une vidéo de 17mn qui ne comporte pas d'effet ne viendrait pas de là ?
    Vu que je ne sais pas à quoi sert cette option.
    Ahmotiond

    You are not missing anything. This is how it works now in CC.

  • Sending escape sequences to control command line printing

    Hello Java Community,
    I am interested in printing PDF files programatically by using a thread that used the runtime environment and the sending a command to print the file.
    I hava managed to print files directly to the printer using "cmd /c acrord32.exe /h /p filename.pdf" thanks to iText FAQ.
    The problem is that when I try sending the job to an Epson LX 300 printer, the job prints in letter quality while my intention is to print in draft mode.
    I imagine that this problem could be resolved by passing escape sequences to set draft mode printing programatically so as to speed up my printing.
    Anyone who can help me on how to achieve this.
    Will appreciate your help.
    Charles

    Reply 1 of http://forum.java.sun.com/thread.jspa?threadID=5226995&messageID=9958472

  • Escape sequence on sender file adapter

    Hello XI experts,
    My scenario is,
       Customer System&#12288;=>  <CSV File> => File Adapter => Integration Engine
    I'm thinking of using Sender File Adapter with File Content Conversion
    and setting "," as  FieldSeparator.
    If there is "," in a text field and I don't want the Adapter to recognize it
    as separator, how can I difine escape sequence?
    For example,
    #default#
    aaa,bbb,ccc,SAP,Oracle....
    ->
    aaa
    bbb
    ccc
    SAP
    Oracle
    #My requirement - define & as escape sequence#
    aaa,bbb,ccc,SAP&,Oracle....
    ->
    aaa
    bbb
    ccc
    SAP,Oracle
    Any infomaton is appreciated.
    Regards,
    Tomoatsu

    Hi,
    You can use the following parmeter: NameA.enclosureSign
    Check here for the same:
    http://help.sap.com/saphelp_nw04/helpdata/en/2c/181077dd7d6b4ea6a8029b20bf7e55/content.htm
    Regards
    Vijaya

  • Have a problem in Formatting output with Escape Sequence

    class Welcome
         public static void main(String args[])
              //Khong the hieu noi
              System.out.println("Welcome\tto the world of java");
              System.out.println("Happy\tBirthday");
              System.out.println("Welcome\" to the world of java");
              System.out.println("Bo\ttay");
              System.out.println("Be\ttay");
              System.out.println("Nhe\ttay");
              System.out.println("Welcome\tto Viet Nam");
              System.out.println("?Welcome\tto Viet Nam");
              System.out.println("!Welcome\tto Viet Nam");
              System.out.println("*Welcome\tto Viet Nam");
              System.out.println("#Welcome\tto Viet Nam");
              System.out.println("$Welcome\tto Viet Nam");
              System.out.println("%Welcome\tto Viet Nam");
              System.out.println("^Welcome\tto Viet Nam");
              System.out.println("&Welcome\tto Viet Nam");
              System.out.println("/Welcome\tto Viet Nam");
              System.out.println("Welcome\tto Viet Nam");
              System.out.println(" Welcome\tto Viet Nam");
              System.out.println(" Welcome\tto Viet Nam");
              System.out.println(" Welcome\tto Viet Nam");
              System.out.println(" Welcome\tto Viet Nam");
              System.out.println(" Welcome\tto Viet Nam");
              System.out.println(" Welcome\tto Viet Nam");
              System.out.println(" Welcome\tto Viet Nam");
              System.out.println(" Welcome\tto Viet Nam");
              System.out.println(" Welcome\tto Viet Nam");
              System.out.println("Bodsdsadsme\ttay");
              System.out.println("come\tto");
    Let's explain for me...Thanks

    Dou you have a question ?
    The character and string escape sequences allow for the representation of some nongraphic characters as well as the single quote, double quote, and backslash characters in character literals and string literals:'\b'     /* \u0008: backspace       */
    '\t'     /* \u0009: horizontal tab  */
    '\n'     /* \u000a: linefeed        */
    '\f'     /* \u000c: form feed       */
    '\r'     /* \u000d: carriage return */
    '\"'     /* \u0022: double quote    */
    '\''     /* \u0027: single quote    */
    '\\'     /* \u005c: backslash       */In case you are using Java 1.5, you might be interested in System.out.printf(), which usesformat string.

Maybe you are looking for

  • Error while altering a table in Oracle Portal

    i have a table with primary key. i realize that the primary is not required and when i get rid of primary key thru Oracle Portal and say OK ... i am encountered with the following error - Error: ORA-25150: ALTERING of extent parameters not permitted

  • Problem opening a 6.0.1 file on keynote 5.3

    Hey Guys, need your help. First about sorry for my english, I'll try to do my best... I recently made a downgrade from Mavericks to Mountain Lion because I had some problems. The thing is that I created a Keynote presentation with the last version of

  • Good receipt details

    Hi experts, Iam trying to extract the data from good receipt(MIGO). In my document number there is no Material existing.But material description is existing. Where can i find this material description for the particular document number? Is there any

  • Error Updating CS6 apps

    Everytime I try an update a few of my CS6 apps I get an error during installation. Error code (U44M1P7). Any fix for this?

  • FM to get desktop path

    Hi Exports,     Is there any function module to get the desktop path in our presentation server? It means that I should not browse the path using F4_FILENAME and all. That function module should give my desktop path automatically.    Or otherwise is