x11vnc: improve XFIXES cursor transparency, more remote-control cmds.

pull/1/head
runge 20 years ago
parent c9a69485ec
commit 4b89306d17

@ -1,3 +1,7 @@
2004-12-27 Karl Runge <runge@karlrunge.com>
* x11vnc: improve alpha channel handling for XFIXES cursors.
* add more parameters to remote control.
2004-12-20 Johannes E. Schindelin <Johannes.Schindelin@gmx.de> 2004-12-20 Johannes E. Schindelin <Johannes.Schindelin@gmx.de>
* released version 0.7 * released version 0.7

@ -1,3 +1,11 @@
2004-12-27 Karl Runge <runge@karlrunge.com>
* allow -DLIBVNCSERVER_HAVE_FOO=0 override everything
* get_xfixes_cursor() try to more carefully convert alpha channel
to opaque pixel. Options -alphacut, -alphafrac, -alpharemove
* more commands under remote control: rfbwait, rfbport, http,
httpport, httpdir, enablehttpproxy, desktop, alwaysshared,
dontdisconnect. Add to tkx11vnc.
2004-12-22 Karl Runge <runge@karlrunge.com> 2004-12-22 Karl Runge <runge@karlrunge.com>
* final polishing for 0.7 release, tkx11vnc tweaks * final polishing for 0.7 release, tkx11vnc tweaks
* more careful rfbPE in pick_window, start check_user_input4() * more careful rfbPE in pick_window, start check_user_input4()

File diff suppressed because it is too large Load Diff

@ -89,6 +89,7 @@ Clients
gone: gone:
vncconnect vncconnect
-- --
http
=F httpdir: =F httpdir:
httpport: httpport:
enablehttpproxy enablehttpproxy
@ -167,6 +168,8 @@ Debugging
debug_pointer debug_pointer
debug_keyboard debug_keyboard
=F logfile: =F logfile:
=GA show-logfile
=GA tail-logfile
quiet quiet
-- --
=GA show-start-cmd =GA show-start-cmd
@ -187,9 +190,9 @@ Permissions
-- --
=RA noremote =RA noremote
-- --
alwaysshared =SA alwaysshared
nevershared =SA nevershared
dontdisconnect =SA dontdisconnect
-- --
viewpasswd: viewpasswd:
=F passwdfile: =F passwdfile:
@ -204,6 +207,9 @@ Tuning
=-C:1,2,3,4 pointer_mode: =-C:1,2,3,4 pointer_mode:
input_skip: input_skip:
nodragging nodragging
alphacut:
alphafrac:
alpharemove
-- --
=D noshm =D noshm
flipbyteorder flipbyteorder
@ -289,6 +295,15 @@ a -Q query. Examples: \"zero:20,20,100,100\", \"Q:ext_xfixes\"
set helptext(stop+quit) " set helptext(stop+quit) "
Send the stop command to the x11vnc server, then terminate the tkx11vnc gui. Send the stop command to the x11vnc server, then terminate the tkx11vnc gui.
"
set helptext(show-logfile) "
View the current contents of the logfile (if it exists and is accessible
by the gui process).
"
set helptext(tail-logfile) "
Run the tail(1) command with -f option on the logfile in an xterm.
" "
set helptext(Quit) " set helptext(Quit) "
@ -392,6 +407,20 @@ Key Bindings:
Anywhere: Control-p invokes \"Actions -> ping\" Anywhere: Control-p invokes \"Actions -> ping\"
Anywhere: Control-u and Control-r invoke \"Actions -> update-all\" Anywhere: Control-u and Control-r invoke \"Actions -> update-all\"
Misc:
Since x11vnc has so many settings and to avoid further confusion,
the libvncserver options:
-alwaysshared
-nevershared
-dontdisconnect
are not available for changing in a running x11vnc (even though it
is feasible). These options overlap with the x11vnc options -shared
and -forever which are hopefully enough for most usage. They may be
specified for x11vnc startup if desired.
" "
} }
@ -506,8 +535,8 @@ proc active_when_starting {item} {
} }
proc help_win {item} { proc help_win {item} {
global helptext helpremote global helptext helpremote menu_var
global query_ans query_aro; global query_ans query_aro
set ok 0 set ok 0
set text "Help on $item:\n\n" set text "Help on $item:\n\n"
@ -551,6 +580,18 @@ proc help_win {item} {
set ok 1 set ok 1
} }
if {![is_action $item] && [info exists menu_var($item)]} {
global unset_str
append text "\n\n"
append text "==== current $item value: ====\n";
append text "\n"
if {$menu_var($item) == ""} {
append text "$unset_str\n"
} else {
append text "$menu_var($item)\n"
}
}
if {$item == "start"} { if {$item == "start"} {
set str [get_start_x11vnc_txt] set str [get_start_x11vnc_txt]
append text $str append text $str
@ -799,15 +840,20 @@ proc menus_disable {} {
# Entry box utilities: # Entry box utilities:
proc entry_state {x state} { proc entry_state {x state} {
global entry_box entry_label entry_ok entry_help entry_skip entry_browse global entry_box entry_label entry_ok entry_help entry_skip entry_browse
global old_labels
if {$x == "all"} { if {$x == "all"} {
$entry_label configure -state $state if {!$old_labels} {
$entry_label configure -state $state
}
$entry_box configure -state $state $entry_box configure -state $state
$entry_ok configure -state $state $entry_ok configure -state $state
$entry_skip configure -state $state $entry_skip configure -state $state
$entry_help configure -state $state $entry_help configure -state $state
$entry_browse configure -state $state $entry_browse configure -state $state
} elseif {$x == "label"} { } elseif {$x == "label"} {
$entry_label configure -state $state if {!$old_labels} {
$entry_label configure -state $state
}
} elseif {$x == "box"} { } elseif {$x == "box"} {
$entry_box configure -state $state $entry_box configure -state $state
} elseif {$x == "ok"} { } elseif {$x == "ok"} {
@ -1336,7 +1382,11 @@ proc query_all {{quiet 0}} {
} }
proc set_info {str} { proc set_info {str} {
global info_str global info_str info_label
#set w1 [$info_label cget -width]
#set w2 [winfo width $info_label]
#puts "set_info: w=$w1 winfo=$w2"
#append_text "$str\n"
set info_str "$str" set info_str "$str"
update update
} }
@ -1360,6 +1410,55 @@ proc show_all_settings {} {
textwin "Settings" "All Current Settings" $txt textwin "Settings" "All Current Settings" $txt
} }
proc show_logfile {} {
global menu_var unset_str
set logfile $menu_var(logfile)
if {$logfile == "" || $logfile == $unset_str} {
set txt "\nNo logfile has been specified.\n\n"
} elseif {![file exists $logfile]} {
set txt "\nLogfile \"$logfile\" does not exist.\n\n"
} else {
set fh "-3"
set err ""
catch {set fh [open $logfile "r"]} err
if {$fh == "-3"} {
set txt "\nError opening \"$logfile\" $err.\n\n"
} else {
set txt "\nLogfile \"$logfile\" current contents:\n"
while {[gets $fh line] > -1} {
append txt "$line\n"
}
close $fh
}
}
textwin "Logfile" "Logfile" $txt
}
proc tail_logfile {} {
global menu_var unset_str
set logfile $menu_var(logfile)
set txt ""
if {$logfile == "" || $logfile == $unset_str} {
set txt "\nNo logfile has been specified.\n\n"
} elseif {![file exists $logfile]} {
set txt "\nLogfile \"$logfile\" does not exist.\n\n"
} else {
set cmd ""
set xterm_cmd "xterm -geometry 80x45 -title x11vnc-logfile -e"
set cmd [split $xterm_cmd]
lappend cmd "tail"
lappend cmd "+1f"
lappend cmd $logfile
lappend cmd "&"
catch {[eval exec $cmd]}
}
if {$txt != ""} {
textwin "Logfile" "Logfile" $txt
}
}
proc set_connected {yesno} { proc set_connected {yesno} {
global connected_to_x11vnc global connected_to_x11vnc
set orig $connected_to_x11vnc set orig $connected_to_x11vnc
@ -1422,6 +1521,12 @@ proc do_action {item} {
} elseif {$item == "all-settings"} { } elseif {$item == "all-settings"} {
show_all_settings show_all_settings
return return
} elseif {$item == "show-logfile"} {
show_logfile
return
} elseif {$item == "tail-logfile"} {
tail_logfile
return
} elseif {$item == "stop+quit"} { } elseif {$item == "stop+quit"} {
push_new_value "stop" "stop" 1 0 push_new_value "stop" "stop" 1 0
set_connected no set_connected no
@ -1666,7 +1771,7 @@ proc disconnect_dialog {client} {
append_text "Invalid client info string: $client\n" append_text "Invalid client info string: $client\n"
return return
} }
append msg "*** To disconnect this client press \"OK\", otherwise press \"Skip\"\n" append msg "*** To *DISCONNECT* this client press \"OK\", otherwise press \"Skip\"\n"
bell bell
if [warning_dialog $msg "current"] { if [warning_dialog $msg "current"] {
push_new_value "disconnect" "disconnect" $cid 1 push_new_value "disconnect" "disconnect" $cid 1
@ -1757,17 +1862,19 @@ proc make_widgets {} {
global menu_b menu_m global menu_b menu_m
global item_opts item_bool item_case item_entry menu_var unset_str global item_opts item_bool item_case item_entry menu_var unset_str
global item_cascade global item_cascade
global info_str x11_display vnc_display global info_label info_str x11_display vnc_display
global text_area global text_area
global entry_box entry_str entry_set entry_label entry_ok entry_browse global entry_box entry_str entry_set entry_label entry_ok entry_browse
global entry_help entry_skip global entry_help entry_skip
global bfont global bfont
global helptext helpremote helplabel global helptext helpremote helplabel
set v 0 set label_width 80
label .info -textvariable info_str -bd 2 -relief groove -anchor w set info_label .info
pack .info -side top -fill x label $info_label -textvariable info_str -bd 2 -relief groove \
-anchor w -width $label_width
pack $info_label -side top -fill x -expand 0
# Extract the Rows: # Extract the Rows:
set row 0; set row 0;
@ -1869,7 +1976,7 @@ set v 0
set item_cascade($item) "" set item_cascade($item) ""
set item_entry($item) $menu_count($case) set item_entry($item) $menu_count($case)
if {$v} { puts "ITEM: $item - $opts - $case - $bool - $menu_count($case)" } if {0} { puts "ITEM: $item - $opts - $case - $bool - $menu_count($case)" }
set mvar 0 set mvar 0
set m $menu_m($case) set m $menu_m($case)
@ -1947,8 +2054,6 @@ if {$v} { puts "ITEM: $item - $opts - $case - $bool - $menu_count($case)" }
set m $menu_m($case); set m $menu_m($case);
set n [$m index end] set n [$m index end]
if {$v} { puts "$case end: $n" }
for {set i 0} {$i <= $n} {incr i} { for {set i 0} {$i <= $n} {incr i} {
set type [$m type $i] set type [$m type $i]
if {$type == "separator"} { if {$type == "separator"} {
@ -1966,13 +2071,6 @@ if {$v} { puts "$case end: $n" }
$m add command -label $str \ $m add command -label $str \
-command "menu_help $label"; -command "menu_help $label";
if {$v} {
set ht ""; set hr ""
if {[info exists helptext($label)]} { set ht "YES" }
if {[info exists helpremote($label)]} { set hr "YES" }
puts "'$label'\tht='$ht' hr='$hr'"
}
if {$str == ""} { if {$str == ""} {
$m entryconfigure end -state disabled $m entryconfigure end -state disabled
} }
@ -1994,11 +2092,13 @@ if {$v} {
set df_x11 "$df.xdisplay" set df_x11 "$df.xdisplay"
no_x11_display no_x11_display
label $df_x11 -textvariable x11_display -width 35 -anchor w
set lw [expr {$label_width / 2}]
label $df_x11 -textvariable x11_display -width $lw -anchor w
set df_vnc "$df.vdisplay" set df_vnc "$df.vdisplay"
no_vnc_display no_vnc_display
label $df_vnc -textvariable vnc_display -width 35 -anchor w label $df_vnc -textvariable vnc_display -width $lw -anchor w
pack $df_x11 $df_vnc -side left pack $df_x11 $df_vnc -side left
pack $df -side top -fill x pack $df -side top -fill x
@ -2016,7 +2116,7 @@ if {$v} {
set ef .entryframe set ef .entryframe
frame $ef -bd 1 -relief groove frame $ef -bd 1 -relief groove
# Label # Entry Label
set ef_label "$ef.label" set ef_label "$ef.label"
label $ef_label -textvariable entry_str -anchor w -font $bfont label $ef_label -textvariable entry_str -anchor w -font $bfont
@ -2026,22 +2126,22 @@ if {$v} {
bind $ef_entry <KeyPress-Return> {set entry_set 1} bind $ef_entry <KeyPress-Return> {set entry_set 1}
bind $ef_entry <KeyPress-Escape> {set entry_set 0} bind $ef_entry <KeyPress-Escape> {set entry_set 0}
# OK button # Entry OK button
set ef_ok "$ef.ok" set ef_ok "$ef.ok"
button $ef_ok -text OK -pady 1 -command {set entry_set 1} \ button $ef_ok -text OK -pady 1 -command {set entry_set 1} \
-font $bfont -font $bfont
# Skip button # Entry Skip button
set ef_skip "$ef.skip" set ef_skip "$ef.skip"
button $ef_skip -text Skip -pady 0 -command {set entry_set 0} \ button $ef_skip -text Skip -pady 0 -command {set entry_set 0} \
-font $bfont -font $bfont
# Help button # Entry Help button
set ef_help "$ef.help" set ef_help "$ef.help"
button $ef_help -text Help -pady 0 -command \ button $ef_help -text Help -pady 0 -command \
{menu_help $entry_dialog_item} -font $bfont {menu_help $entry_dialog_item} -font $bfont
# Browse button # Entry Browse button
set ef_browse "$ef.browse" set ef_browse "$ef.browse"
button $ef_browse -text "Browse..." -pady 0 -font $bfont \ button $ef_browse -text "Browse..." -pady 0 -font $bfont \
-command {entry_insert [tk_getOpenFile]} -command {entry_insert [tk_getOpenFile]}
@ -2063,6 +2163,11 @@ if {$v} {
update update
wm minsize . [winfo width .] [winfo height .] wm minsize . [winfo width .] [winfo height .]
#set w [winfo width .info]
#puts "w1: $w"
#set w [winfo reqwidth .info]
#puts "w2: $w"
} }
proc menu_bindings {} { proc menu_bindings {} {
@ -2329,13 +2434,13 @@ proc run_remote_cmd {opts} {
lappend cmd "2>" lappend cmd "2>"
lappend cmd "/dev/null" lappend cmd "/dev/null"
if {0} { if {0} {
set str [join $cmd] set str [join $cmd]
puts "running: $str" puts "running: $str"
foreach word $cmd { foreach word $cmd {
puts " word: $word" puts " word: $word"
}
} }
}
set output "" set output ""
menus_disable menus_disable
@ -2414,7 +2519,7 @@ global helpall helptext helpremote helplabel hostname;
global all_settings reply_xdisplay always_update global all_settings reply_xdisplay always_update
global max_text_height max_text_width global max_text_height max_text_width
global menu_var unset_str menus_disabled global menu_var unset_str menus_disabled
global bfont global bfont old_labels
global connected_to_x11vnc global connected_to_x11vnc
global delay_sleep extra_sleep extra_sleep_split global delay_sleep extra_sleep extra_sleep_split
global cache_all_query_vars global cache_all_query_vars
@ -2436,6 +2541,12 @@ set delay_sleep 350
set extra_sleep 1000 set extra_sleep 1000
set extra_sleep_split 4 set extra_sleep_split 4
if {[regexp {^[34]} $tk_version] || $tk_version == "8.0"} {
set old_labels 1
} else {
set old_labels 0
}
if {"$argv" == "-spit"} { if {"$argv" == "-spit"} {
set fh [open $argv0 r] set fh [open $argv0 r]
puts "/*" puts "/*"

@ -95,6 +95,7 @@
" gone:\n" " gone:\n"
" vncconnect\n" " vncconnect\n"
" --\n" " --\n"
" http\n"
" =F httpdir:\n" " =F httpdir:\n"
" httpport:\n" " httpport:\n"
" enablehttpproxy\n" " enablehttpproxy\n"
@ -173,6 +174,8 @@
" debug_pointer\n" " debug_pointer\n"
" debug_keyboard\n" " debug_keyboard\n"
" =F logfile:\n" " =F logfile:\n"
" =GA show-logfile\n"
" =GA tail-logfile\n"
" quiet\n" " quiet\n"
" --\n" " --\n"
" =GA show-start-cmd\n" " =GA show-start-cmd\n"
@ -193,9 +196,9 @@
" --\n" " --\n"
" =RA noremote\n" " =RA noremote\n"
" --\n" " --\n"
" alwaysshared\n" " =SA alwaysshared\n"
" nevershared\n" " =SA nevershared\n"
" dontdisconnect\n" " =SA dontdisconnect\n"
" --\n" " --\n"
" viewpasswd:\n" " viewpasswd:\n"
" =F passwdfile:\n" " =F passwdfile:\n"
@ -210,6 +213,9 @@
" =-C:1,2,3,4 pointer_mode:\n" " =-C:1,2,3,4 pointer_mode:\n"
" input_skip:\n" " input_skip:\n"
" nodragging\n" " nodragging\n"
" alphacut:\n"
" alphafrac:\n"
" alpharemove\n"
" --\n" " --\n"
" =D noshm\n" " =D noshm\n"
" flipbyteorder\n" " flipbyteorder\n"
@ -297,6 +303,15 @@
"Send the stop command to the x11vnc server, then terminate the tkx11vnc gui.\n" "Send the stop command to the x11vnc server, then terminate the tkx11vnc gui.\n"
"\"\n" "\"\n"
"\n" "\n"
" set helptext(show-logfile) \"\n"
"View the current contents of the logfile (if it exists and is accessible\n"
"by the gui process).\n"
"\"\n"
"\n"
" set helptext(tail-logfile) \"\n"
"Run the tail(1) command with -f option on the logfile in an xterm.\n"
"\"\n"
"\n"
" set helptext(Quit) \"\n" " set helptext(Quit) \"\n"
"Terminate the tkx11vnc gui. Any x11vnc servers will be left running.\n" "Terminate the tkx11vnc gui. Any x11vnc servers will be left running.\n"
"\"\n" "\"\n"
@ -398,6 +413,20 @@
" Anywhere: Control-p invokes \\\"Actions -> ping\\\"\n" " Anywhere: Control-p invokes \\\"Actions -> ping\\\"\n"
" Anywhere: Control-u and Control-r invoke \\\"Actions -> update-all\\\"\n" " Anywhere: Control-u and Control-r invoke \\\"Actions -> update-all\\\"\n"
"\n" "\n"
"Misc:\n"
"\n"
"Since x11vnc has so many settings and to avoid further confusion,\n"
"the libvncserver options:\n"
"\n"
" -alwaysshared\n"
" -nevershared\n"
" -dontdisconnect\n"
"\n"
"are not available for changing in a running x11vnc (even though it\n"
"is feasible). These options overlap with the x11vnc options -shared\n"
"and -forever which are hopefully enough for most usage. They may be\n"
"specified for x11vnc startup if desired.\n"
"\n"
"\"\n" "\"\n"
"}\n" "}\n"
"\n" "\n"
@ -512,8 +541,8 @@
"}\n" "}\n"
"\n" "\n"
"proc help_win {item} {\n" "proc help_win {item} {\n"
" global helptext helpremote\n" " global helptext helpremote menu_var\n"
" global query_ans query_aro;\n" " global query_ans query_aro\n"
"\n" "\n"
" set ok 0\n" " set ok 0\n"
" set text \"Help on $item:\\n\\n\"\n" " set text \"Help on $item:\\n\\n\"\n"
@ -557,6 +586,18 @@
" set ok 1\n" " set ok 1\n"
" }\n" " }\n"
"\n" "\n"
" if {![is_action $item] && [info exists menu_var($item)]} {\n"
" global unset_str\n"
" append text \"\\n\\n\"\n"
" append text \"==== current $item value: ====\\n\";\n"
" append text \"\\n\"\n"
" if {$menu_var($item) == \"\"} {\n"
" append text \"$unset_str\\n\"\n"
" } else {\n"
" append text \"$menu_var($item)\\n\"\n"
" }\n"
" }\n"
"\n"
" if {$item == \"start\"} {\n" " if {$item == \"start\"} {\n"
" set str [get_start_x11vnc_txt]\n" " set str [get_start_x11vnc_txt]\n"
" append text $str\n" " append text $str\n"
@ -805,15 +846,20 @@
"# Entry box utilities:\n" "# Entry box utilities:\n"
"proc entry_state {x state} {\n" "proc entry_state {x state} {\n"
" global entry_box entry_label entry_ok entry_help entry_skip entry_browse\n" " global entry_box entry_label entry_ok entry_help entry_skip entry_browse\n"
" global old_labels\n"
" if {$x == \"all\"} {\n" " if {$x == \"all\"} {\n"
" $entry_label configure -state $state\n" " if {!$old_labels} {\n"
" $entry_label configure -state $state\n"
" }\n"
" $entry_box configure -state $state\n" " $entry_box configure -state $state\n"
" $entry_ok configure -state $state\n" " $entry_ok configure -state $state\n"
" $entry_skip configure -state $state\n" " $entry_skip configure -state $state\n"
" $entry_help configure -state $state\n" " $entry_help configure -state $state\n"
" $entry_browse configure -state $state\n" " $entry_browse configure -state $state\n"
" } elseif {$x == \"label\"} {\n" " } elseif {$x == \"label\"} {\n"
" $entry_label configure -state $state\n" " if {!$old_labels} {\n"
" $entry_label configure -state $state\n"
" }\n"
" } elseif {$x == \"box\"} {\n" " } elseif {$x == \"box\"} {\n"
" $entry_box configure -state $state\n" " $entry_box configure -state $state\n"
" } elseif {$x == \"ok\"} {\n" " } elseif {$x == \"ok\"} {\n"
@ -1342,7 +1388,11 @@
"}\n" "}\n"
"\n" "\n"
"proc set_info {str} {\n" "proc set_info {str} {\n"
" global info_str\n" " global info_str info_label\n"
"#set w1 [$info_label cget -width]\n"
"#set w2 [winfo width $info_label]\n"
"#puts \"set_info: w=$w1 winfo=$w2\"\n"
"#append_text \"$str\\n\"\n"
" set info_str \"$str\"\n" " set info_str \"$str\"\n"
" update\n" " update\n"
"}\n" "}\n"
@ -1366,6 +1416,55 @@
" textwin \"Settings\" \"All Current Settings\" $txt\n" " textwin \"Settings\" \"All Current Settings\" $txt\n"
"}\n" "}\n"
"\n" "\n"
"proc show_logfile {} {\n"
" global menu_var unset_str\n"
" set logfile $menu_var(logfile)\n"
" \n"
" if {$logfile == \"\" || $logfile == $unset_str} {\n"
" set txt \"\\nNo logfile has been specified.\\n\\n\" \n"
" } elseif {![file exists $logfile]} {\n"
" set txt \"\\nLogfile \\\"$logfile\\\" does not exist.\\n\\n\"\n"
" } else {\n"
" set fh \"-3\"\n"
" set err \"\"\n"
" catch {set fh [open $logfile \"r\"]} err\n"
" if {$fh == \"-3\"} {\n"
" set txt \"\\nError opening \\\"$logfile\\\" $err.\\n\\n\"\n"
" } else {\n"
" set txt \"\\nLogfile \\\"$logfile\\\" current contents:\\n\"\n"
" while {[gets $fh line] > -1} {\n"
" append txt \"$line\\n\"\n"
" }\n"
" close $fh\n"
" }\n"
" }\n"
" textwin \"Logfile\" \"Logfile\" $txt\n"
"}\n"
"\n"
"proc tail_logfile {} {\n"
" global menu_var unset_str\n"
" set logfile $menu_var(logfile)\n"
" \n"
" set txt \"\"\n"
" if {$logfile == \"\" || $logfile == $unset_str} {\n"
" set txt \"\\nNo logfile has been specified.\\n\\n\" \n"
" } elseif {![file exists $logfile]} {\n"
" set txt \"\\nLogfile \\\"$logfile\\\" does not exist.\\n\\n\"\n"
" } else {\n"
" set cmd \"\"\n"
" set xterm_cmd \"xterm -geometry 80x45 -title x11vnc-logfile -e\"\n"
" set cmd [split $xterm_cmd]\n"
" lappend cmd \"tail\"\n"
" lappend cmd \"+1f\"\n"
" lappend cmd $logfile\n"
" lappend cmd \"&\"\n"
" catch {[eval exec $cmd]}\n"
" }\n"
" if {$txt != \"\"} {\n"
" textwin \"Logfile\" \"Logfile\" $txt\n"
" }\n"
"}\n"
"\n"
"proc set_connected {yesno} {\n" "proc set_connected {yesno} {\n"
" global connected_to_x11vnc\n" " global connected_to_x11vnc\n"
" set orig $connected_to_x11vnc\n" " set orig $connected_to_x11vnc\n"
@ -1428,6 +1527,12 @@
" } elseif {$item == \"all-settings\"} {\n" " } elseif {$item == \"all-settings\"} {\n"
" show_all_settings\n" " show_all_settings\n"
" return\n" " return\n"
" } elseif {$item == \"show-logfile\"} {\n"
" show_logfile\n"
" return\n"
" } elseif {$item == \"tail-logfile\"} {\n"
" tail_logfile\n"
" return\n"
" } elseif {$item == \"stop+quit\"} {\n" " } elseif {$item == \"stop+quit\"} {\n"
" push_new_value \"stop\" \"stop\" 1 0\n" " push_new_value \"stop\" \"stop\" 1 0\n"
" set_connected no\n" " set_connected no\n"
@ -1672,7 +1777,7 @@
" append_text \"Invalid client info string: $client\\n\"\n" " append_text \"Invalid client info string: $client\\n\"\n"
" return\n" " return\n"
" }\n" " }\n"
" append msg \"*** To disconnect this client press \\\"OK\\\", otherwise press \\\"Skip\\\"\\n\"\n" " append msg \"*** To *DISCONNECT* this client press \\\"OK\\\", otherwise press \\\"Skip\\\"\\n\"\n"
" bell\n" " bell\n"
" if [warning_dialog $msg \"current\"] {\n" " if [warning_dialog $msg \"current\"] {\n"
" push_new_value \"disconnect\" \"disconnect\" $cid 1\n" " push_new_value \"disconnect\" \"disconnect\" $cid 1\n"
@ -1763,17 +1868,19 @@
" global menu_b menu_m\n" " global menu_b menu_m\n"
" global item_opts item_bool item_case item_entry menu_var unset_str\n" " global item_opts item_bool item_case item_entry menu_var unset_str\n"
" global item_cascade\n" " global item_cascade\n"
" global info_str x11_display vnc_display\n" " global info_label info_str x11_display vnc_display\n"
" global text_area\n" " global text_area\n"
" global entry_box entry_str entry_set entry_label entry_ok entry_browse\n" " global entry_box entry_str entry_set entry_label entry_ok entry_browse\n"
" global entry_help entry_skip\n" " global entry_help entry_skip\n"
" global bfont\n" " global bfont\n"
" global helptext helpremote helplabel\n" " global helptext helpremote helplabel\n"
"\n" "\n"
"set v 0\n" " set label_width 80\n"
" \n" "\n"
" label .info -textvariable info_str -bd 2 -relief groove -anchor w \n" " set info_label .info\n"
" pack .info -side top -fill x \n" " label $info_label -textvariable info_str -bd 2 -relief groove \\\n"
" -anchor w -width $label_width\n"
" pack $info_label -side top -fill x -expand 0\n"
"\n" "\n"
" # Extract the Rows:\n" " # Extract the Rows:\n"
" set row 0;\n" " set row 0;\n"
@ -1875,7 +1982,7 @@
" set item_cascade($item) \"\"\n" " set item_cascade($item) \"\"\n"
" set item_entry($item) $menu_count($case)\n" " set item_entry($item) $menu_count($case)\n"
"\n" "\n"
"if {$v} { puts \"ITEM: $item - $opts - $case - $bool - $menu_count($case)\" }\n" " if {0} { puts \"ITEM: $item - $opts - $case - $bool - $menu_count($case)\" }\n"
"\n" "\n"
" set mvar 0 \n" " set mvar 0 \n"
" set m $menu_m($case)\n" " set m $menu_m($case)\n"
@ -1953,8 +2060,6 @@
" set m $menu_m($case);\n" " set m $menu_m($case);\n"
" set n [$m index end]\n" " set n [$m index end]\n"
"\n" "\n"
"if {$v} { puts \"$case end: $n\" }\n"
"\n"
" for {set i 0} {$i <= $n} {incr i} {\n" " for {set i 0} {$i <= $n} {incr i} {\n"
" set type [$m type $i]\n" " set type [$m type $i]\n"
" if {$type == \"separator\"} {\n" " if {$type == \"separator\"} {\n"
@ -1972,13 +2077,6 @@
" $m add command -label $str \\\n" " $m add command -label $str \\\n"
" -command \"menu_help $label\";\n" " -command \"menu_help $label\";\n"
"\n" "\n"
"if {$v} {\n"
" set ht \"\"; set hr \"\"\n"
" if {[info exists helptext($label)]} { set ht \"YES\" }\n"
" if {[info exists helpremote($label)]} { set hr \"YES\" }\n"
" puts \"'$label'\\tht='$ht' hr='$hr'\"\n"
"}\n"
"\n"
" if {$str == \"\"} {\n" " if {$str == \"\"} {\n"
" $m entryconfigure end -state disabled\n" " $m entryconfigure end -state disabled\n"
" }\n" " }\n"
@ -2000,11 +2098,13 @@
"\n" "\n"
" set df_x11 \"$df.xdisplay\"\n" " set df_x11 \"$df.xdisplay\"\n"
" no_x11_display\n" " no_x11_display\n"
" label $df_x11 -textvariable x11_display -width 35 -anchor w\n" "\n"
" set lw [expr {$label_width / 2}]\n"
" label $df_x11 -textvariable x11_display -width $lw -anchor w\n"
"\n" "\n"
" set df_vnc \"$df.vdisplay\"\n" " set df_vnc \"$df.vdisplay\"\n"
" no_vnc_display\n" " no_vnc_display\n"
" label $df_vnc -textvariable vnc_display -width 35 -anchor w\n" " label $df_vnc -textvariable vnc_display -width $lw -anchor w\n"
"\n" "\n"
" pack $df_x11 $df_vnc -side left \n" " pack $df_x11 $df_vnc -side left \n"
" pack $df -side top -fill x\n" " pack $df -side top -fill x\n"
@ -2022,7 +2122,7 @@
" set ef .entryframe\n" " set ef .entryframe\n"
" frame $ef -bd 1 -relief groove\n" " frame $ef -bd 1 -relief groove\n"
"\n" "\n"
" # Label\n" " # Entry Label\n"
" set ef_label \"$ef.label\"\n" " set ef_label \"$ef.label\"\n"
" label $ef_label -textvariable entry_str -anchor w -font $bfont\n" " label $ef_label -textvariable entry_str -anchor w -font $bfont\n"
"\n" "\n"
@ -2032,22 +2132,22 @@
" bind $ef_entry <KeyPress-Return> {set entry_set 1}\n" " bind $ef_entry <KeyPress-Return> {set entry_set 1}\n"
" bind $ef_entry <KeyPress-Escape> {set entry_set 0}\n" " bind $ef_entry <KeyPress-Escape> {set entry_set 0}\n"
"\n" "\n"
" # OK button\n" " # Entry OK button\n"
" set ef_ok \"$ef.ok\"\n" " set ef_ok \"$ef.ok\"\n"
" button $ef_ok -text OK -pady 1 -command {set entry_set 1} \\\n" " button $ef_ok -text OK -pady 1 -command {set entry_set 1} \\\n"
" -font $bfont\n" " -font $bfont\n"
"\n" "\n"
" # Skip button\n" " # Entry Skip button\n"
" set ef_skip \"$ef.skip\"\n" " set ef_skip \"$ef.skip\"\n"
" button $ef_skip -text Skip -pady 0 -command {set entry_set 0} \\\n" " button $ef_skip -text Skip -pady 0 -command {set entry_set 0} \\\n"
" -font $bfont\n" " -font $bfont\n"
"\n" "\n"
" # Help button\n" " # Entry Help button\n"
" set ef_help \"$ef.help\"\n" " set ef_help \"$ef.help\"\n"
" button $ef_help -text Help -pady 0 -command \\\n" " button $ef_help -text Help -pady 0 -command \\\n"
" {menu_help $entry_dialog_item} -font $bfont\n" " {menu_help $entry_dialog_item} -font $bfont\n"
"\n" "\n"
" # Browse button\n" " # Entry Browse button\n"
" set ef_browse \"$ef.browse\"\n" " set ef_browse \"$ef.browse\"\n"
" button $ef_browse -text \"Browse...\" -pady 0 -font $bfont \\\n" " button $ef_browse -text \"Browse...\" -pady 0 -font $bfont \\\n"
" -command {entry_insert [tk_getOpenFile]} \n" " -command {entry_insert [tk_getOpenFile]} \n"
@ -2069,6 +2169,11 @@
"\n" "\n"
" update\n" " update\n"
" wm minsize . [winfo width .] [winfo height .]\n" " wm minsize . [winfo width .] [winfo height .]\n"
"\n"
" #set w [winfo width .info]\n"
" #puts \"w1: $w\"\n"
" #set w [winfo reqwidth .info]\n"
" #puts \"w2: $w\"\n"
"}\n" "}\n"
"\n" "\n"
"proc menu_bindings {} {\n" "proc menu_bindings {} {\n"
@ -2335,13 +2440,13 @@
" lappend cmd \"2>\"\n" " lappend cmd \"2>\"\n"
" lappend cmd \"/dev/null\"\n" " lappend cmd \"/dev/null\"\n"
"\n" "\n"
"if {0} {\n" " if {0} {\n"
" set str [join $cmd]\n" " set str [join $cmd]\n"
" puts \"running: $str\"\n" " puts \"running: $str\"\n"
" foreach word $cmd {\n" " foreach word $cmd {\n"
" puts \" word: $word\"\n" " puts \" word: $word\"\n"
" }\n"
" }\n" " }\n"
"}\n"
"\n" "\n"
" set output \"\"\n" " set output \"\"\n"
" menus_disable\n" " menus_disable\n"
@ -2420,7 +2525,7 @@
"global all_settings reply_xdisplay always_update\n" "global all_settings reply_xdisplay always_update\n"
"global max_text_height max_text_width\n" "global max_text_height max_text_width\n"
"global menu_var unset_str menus_disabled\n" "global menu_var unset_str menus_disabled\n"
"global bfont\n" "global bfont old_labels\n"
"global connected_to_x11vnc\n" "global connected_to_x11vnc\n"
"global delay_sleep extra_sleep extra_sleep_split\n" "global delay_sleep extra_sleep extra_sleep_split\n"
"global cache_all_query_vars\n" "global cache_all_query_vars\n"
@ -2442,6 +2547,12 @@
"set extra_sleep 1000\n" "set extra_sleep 1000\n"
"set extra_sleep_split 4\n" "set extra_sleep_split 4\n"
"\n" "\n"
"if {[regexp {^[34]} $tk_version] || $tk_version == \"8.0\"} {\n"
" set old_labels 1\n"
"} else {\n"
" set old_labels 0\n"
"}\n"
"\n"
"if {\"$argv\" == \"-spit\"} {\n" "if {\"$argv\" == \"-spit\"} {\n"
" set fh [open $argv0 r]\n" " set fh [open $argv0 r]\n"
" puts \"/*\"\n" " puts \"/*\"\n"

@ -2,7 +2,7 @@
.TH X11VNC "1" "December 2004" "x11vnc " "User Commands" .TH X11VNC "1" "December 2004" "x11vnc " "User Commands"
.SH NAME .SH NAME
x11vnc - allow VNC connections to real X11 displays x11vnc - allow VNC connections to real X11 displays
version: 0.7pre, lastmod: 2004-12-23 version: 0.7.1pre, lastmod: 2004-12-27
.SH SYNOPSIS .SH SYNOPSIS
.B x11vnc .B x11vnc
[OPTION]... [OPTION]...
@ -573,6 +573,13 @@ default (see \fB-noxfixes\fR below). This can be disabled
with \fB-nocursor,\fR and also some values of the "mode" with \fB-nocursor,\fR and also some values of the "mode"
option below. option below.
.IP .IP
Note that under XFIXES cursors with transparency
(alpha channel) will not be exactly represented and
so Overlay may be preferred. See also the \fB-alphacut\fR
and \fB-alphafrac\fR options below as fudge factors to try
to improve the situation for cursors with transparency
for a given theme.
.IP
The "mode" string can be used to fine-tune the The "mode" string can be used to fine-tune the
displaying of cursor shapes. It can be used the displaying of cursor shapes. It can be used the
following ways: following ways:
@ -608,6 +615,37 @@ is not available, \fB-overlay\fR mode will be attempted.
Do not use the XFIXES extension to draw the exact cursor Do not use the XFIXES extension to draw the exact cursor
shape even if it is available. shape even if it is available.
.PP .PP
\fB-alphacut\fR \fIn\fR
.IP
When using the XFIXES extension for the cursor shape,
cursors with transparency will not be displayed exactly
(but opaque ones will). This option sets n as a cutoff
for cursors that have transparency ("alpha channel"
with values ranging from 0 to 255) Any cursor pixel with
alpha value less than n becomes completely transparent.
Otherwise the pixel is completely opaque. Default 255
.IP
Note: the options \fB-alphacut,\fR \fB-alphafrac,\fR and \fB-alphafrac\fR
may be removed if a more accurate internal method for
handling cursor transparency is implemented.
.PP
\fB-alphafrac\fR \fIfraction\fR
.IP
With the threshold in \fB-alphacut\fR some cursors will become
almost completely transparent because their alpha values
are not high enough. For those cursors adjust the
alpha threshold until fraction of the non-zero alpha
channel pixels become opaque. Default 0.33
.PP
\fB-alpharemove\fR
.IP
By default, XFIXES cursors pixels with transparency have
the alpha factor multiplied into the RGB color values
(i.e. that corresponding to blending the cursor with a
black background). Specify this option to remove the
alpha factor. (useful for light colored semi-transparent
cursors).
.PP
\fB-nocursorshape\fR \fB-nocursorshape\fR
.IP .IP
Do not use the TightVNC CursorShapeUpdates extension Do not use the TightVNC CursorShapeUpdates extension
@ -998,18 +1036,24 @@ norepeat enable \fB-norepeat\fR mode.
.IP .IP
repeat disable \fB-norepeat\fR mode. repeat disable \fB-norepeat\fR mode.
.IP .IP
nofb enable \fB-nofb\fR mode.
.IP
fb disable \fB-nofb\fR mode.
.IP
bell enable bell (if supported). bell enable bell (if supported).
.IP .IP
nobell disable bell. nobell disable bell.
.IP .IP
sel disable \fB-nosel\fR mode. bell enable bell (if supported).
.IP .IP
nosel enable \fB-nosel\fR mode. nosel enable \fB-nosel\fR mode.
.IP .IP
primary disable \fB-noprimary\fR mode. sel disable \fB-nosel\fR mode.
.IP .IP
noprimary enable \fB-noprimary\fR mode. noprimary enable \fB-noprimary\fR mode.
.IP .IP
primary disable \fB-noprimary\fR mode.
.IP
cursor:mode enable \fB-cursor\fR "mode". cursor:mode enable \fB-cursor\fR "mode".
.IP .IP
show_cursor enable showing a cursor. show_cursor enable showing a cursor.
@ -1021,6 +1065,14 @@ xfixes enable xfixes cursor shape mode.
.IP .IP
noxfixes disable xfixes cursor shape mode. noxfixes disable xfixes cursor shape mode.
.IP .IP
alphacut:n set \fB-alphacut\fR to n.
.IP
alphafrac:f set \fB-alphafrac\fR to f.
.IP
alpharemove enable \fB-alpharemove\fR mode.
.IP
noalpharemove disable \fB-alpharemove\fR mode.
.IP
cursorshape disable \fB-nocursorshape\fR mode. cursorshape disable \fB-nocursorshape\fR mode.
.IP .IP
nocursorshape enable \fB-nocursorshape\fR mode. nocursorshape enable \fB-nocursorshape\fR mode.
@ -1055,6 +1107,8 @@ defer:n set \fB-defer\fR to n ms,same as deferupdate:n
.IP .IP
wait:n set \fB-wait\fR to n ms. wait:n set \fB-wait\fR to n ms.
.IP .IP
rfbwait:n set \fB-rfbwait\fR (rfbMaxClientWait) to n ms.
.IP
nap enable \fB-nap\fR mode. nap enable \fB-nap\fR mode.
.IP .IP
nonap disable \fB-nap\fR mode. nonap disable \fB-nap\fR mode.
@ -1072,8 +1126,36 @@ fuzz:n set \fB-fuzz\fR to n.
progressive:n set libvncserver \fB-progressive\fR slice progressive:n set libvncserver \fB-progressive\fR slice
height parameter to n. height parameter to n.
.IP .IP
file:name run \fB-remote\fR commands from file "name", desktop:str set \fB-desktop\fR name to str for new clients.
one command per line,blank and # skipped .IP
rfbport:n set \fB-rfbport\fR to n.
.IP
http enable http client connections.
.IP
nohttp disable http client connections.
.IP
httpport:n set \fB-httpport\fR to n.
.IP
httpdir:dir set \fB-httpdir\fR to dir (and enable http).
.IP
enablehttpproxy enable \fB-enablehttpproxy\fR mode.
.IP
noenablehttpproxy disable \fB-enablehttpproxy\fR mode.
.IP
alwaysshared enable \fB-alwaysshared\fR mode.
.IP
noalwaysshared disable \fB-alwaysshared\fR mode.
(may interfere with other options)
.IP
nevershared enable \fB-nevershared\fR mode.
.IP
nonevershared disable \fB-nevershared\fR mode.
(may interfere with other options)
.IP
dontdisconnect enable \fB-dontdisconnect\fR mode.
.IP
nodontdisconnect disable \fB-dontdisconnect\fR mode.
(may interfere with other options)
.IP .IP
noremote disable the \fB-remote\fR command processing, noremote disable the \fB-remote\fR command processing,
it cannot be turned back on. it cannot be turned back on.
@ -1138,33 +1220,37 @@ noflashcmap truecolor notruecolor overlay nooverlay
overlay_cursor overlay_yescursor nooverlay_nocursor overlay_cursor overlay_yescursor nooverlay_nocursor
nooverlay_cursor nooverlay_yescursor overlay_nocursor nooverlay_cursor nooverlay_yescursor overlay_nocursor
visual scale viewonly noviewonly shared noshared visual scale viewonly noviewonly shared noshared
forever noforever once deny lock nodeny unlock connect forever noforever once deny lock nodeny unlock
allowonce allow localhost nolocalhost accept gone shm connect allowonce allow localhost nolocalhost accept
noshm flipbyteorder noflipbyteorder onetile noonetile gone shm noshm flipbyteorder noflipbyteorder onetile
blackout xinerama noxinerama xrandr noxrandr xrandr_mode noonetile blackout xinerama noxinerama xrandr noxrandr
padgeom quiet q noquiet modtweak nomodtweak xkb noxkb xrandr_mode padgeom quiet q noquiet modtweak nomodtweak
skip_keycodes add_keysyms noadd_keysyms clear_mods xkb noxkb skip_keycodes add_keysyms noadd_keysyms
noclear_mods clear_keys noclear_keys remap repeat clear_mods noclear_mods clear_keys noclear_keys
norepeat bell nobell sel nosel primary noprimary remap repeat norepeat fb nofb bell nobell sel
cursorshape nocursorshape cursorpos nocursorpos cursor nosel primary noprimary cursorshape nocursorshape
show_cursor noshow_cursor nocursor xfixes noxfixes xwarp cursorpos nocursorpos cursor show_cursor noshow_cursor
xwarppointer noxwarp noxwarppointer buttonmap dragging nocursor xfixes noxfixes alphacut alphafrac alpharemove
nodragging pointer_mode input_skip debug_pointer dp noalpharemove xwarp xwarppointer noxwarp noxwarppointer
nodebug_pointer nodp debug_keyboard dk nodebug_keyboard buttonmap dragging nodragging pointer_mode input_skip
nodk deferupdate defer wait nap nonap sb screen_blank debug_pointer dp nodebug_pointer nodp debug_keyboard
fs gaps grow fuzz progressive noremote dk nodebug_keyboard nodk deferupdate defer wait
.IP rfbwait nap nonap sb screen_blank fs gaps grow fuzz
aro= display vncdisplay desktopname desktop auth progressive rfbport http nohttp httpport httpdir
rootshift scale_str scaled_x scaled_y scale_numer enablehttpproxy noenablehttpproxy alwaysshared
scale_denom scale_fac scaling_noblend scaling_nomult4 noalwaysshared nevershared noalwaysshared dontdisconnect
scaling_pad scaling_interpolate inetd safer unsafe nodontdisconnect desktop noremote
passwdfile using_shm logfile o rc norc h help V version .IP
lastmod bg nofb sigpipe threads clients client_count aro= display vncdisplay desktopname auth rootshift
pid ext_xtest ext_xkb ext_xshm ext_xinerama ext_overlay scale_str scaled_x scaled_y scale_numer scale_denom
ext_xfixes ext_xdamage ext_xrandr rootwin num_buttons scale_fac scaling_noblend scaling_nomult4 scaling_pad
button_mask mouse_x mouse_y bpp depth indexed_color scaling_interpolate inetd safer unsafe passwdfile
dpy_x dpy_y rfbport rfbwait rfbauth passwd alwaysshared using_shm logfile o rc norc h help V version lastmod
dontdisconnect httpdir enablehttpproxy bg sigpipe threads clients client_count pid ext_xtest
ext_xkb ext_xshm ext_xinerama ext_overlay ext_xfixes
ext_xdamage ext_xrandr rootwin num_buttons button_mask
mouse_x mouse_y bpp depth indexed_color dpy_x dpy_y
rfbauth passwd
.PP .PP
\fB-sync\fR \fB-sync\fR
.IP .IP

File diff suppressed because it is too large Load Diff
Loading…
Cancel
Save