select_rect(): no more direct usage of fix_restore_rect() (now done in drawtemprect(xctx->gctiled,...). Some dialogs no more transient (having always on top is a hassle for some). The fix_broken_tiled_fill is now set to 1, make this alternate drawing method the default
This commit is contained in:
parent
e282abb5f1
commit
7842890f0c
|
|
@ -441,6 +441,15 @@
|
|||
<Component Id="cmp2122C826D84E0925566AEC470A7CFABD" Guid="{5A0BC5DF-8405-48BF-859F-B7F3DD89D866}">
|
||||
<File Id="fil02B785B7CCDC980D09CDB2BB23484767" KeyPath="yes" Source="$(var.docSrcDir)\xschem_man\graphs16.png" />
|
||||
</Component>
|
||||
<Component Id="cmpB581F83F49E5962AD7E37BC077F24E1E" Guid="{A1351F99-7A99-465C-A69C-E4F0EECF19DC}">
|
||||
<File Id="fil95E27FFA9242E70A7E36BDA2753AF06E" KeyPath="yes" Source="$(var.docSrcDir)\xschem_man\graphs17.png" />
|
||||
</Component>
|
||||
<Component Id="cmp9F2896DC4627DF350F685875FC198171" Guid="{B89C6C1B-3149-4FF9-A963-E56E40240D0F}">
|
||||
<File Id="fil2043A12E55A7FD920B4497F543F3566D" KeyPath="yes" Source="$(var.docSrcDir)\xschem_man\graphs18.png" />
|
||||
</Component>
|
||||
<Component Id="cmp2E04033BEABEC724FC52D75E042EBBC6" Guid="{3233E753-8FF7-43DB-9A93-A8F5485B7A05}">
|
||||
<File Id="fil1407A9E0E3573D9579B328DE12CA9DCF" KeyPath="yes" Source="$(var.docSrcDir)\xschem_man\graphs19.png" />
|
||||
</Component>
|
||||
<Component Id="cmp7D84114D6FDF0E09CB66A982B3C581C3" Guid="{06F4736F-88F7-459A-BF81-9F04C78C45B7}">
|
||||
<File Id="fil00E7CE2F76CC18FC1618A1670E025C42" KeyPath="yes" Source="$(var.docSrcDir)\xschem_man\gschemtoxschem.png" />
|
||||
</Component>
|
||||
|
|
@ -1259,6 +1268,9 @@
|
|||
<ComponentRef Id="cmp99C532DCC5EF9E1CD1D26BED58B2934E" />
|
||||
<ComponentRef Id="cmpA41BECAFCCD0A01F5DAD18A949FF2827" />
|
||||
<ComponentRef Id="cmp2122C826D84E0925566AEC470A7CFABD" />
|
||||
<ComponentRef Id="cmpB581F83F49E5962AD7E37BC077F24E1E" />
|
||||
<ComponentRef Id="cmp9F2896DC4627DF350F685875FC198171" />
|
||||
<ComponentRef Id="cmp2E04033BEABEC724FC52D75E042EBBC6" />
|
||||
<ComponentRef Id="cmp7D84114D6FDF0E09CB66A982B3C581C3" />
|
||||
<ComponentRef Id="cmpDB80566B13B66B2A92E91DA0585404A9" />
|
||||
<ComponentRef Id="cmp8C7AB373FA963AF5F88C8B394FB28B19" />
|
||||
|
|
|
|||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
|
|
@ -4967,6 +4967,9 @@
|
|||
<Component Id="cmp81121000EE29EDB7D590EC4C84F1AA2A" Guid="{A8F771A4-8B16-49FA-A581-85D0B728E74A}">
|
||||
<File Id="fil34A55EC1C05159C07FC90AED847FFF66" KeyPath="yes" Source="$(var.xschemLibrarySrcDir)\ngspice\autozero_comp.sch" />
|
||||
</Component>
|
||||
<Component Id="cmpD009418B633A058FED795DBEBEBC109A" Guid="{F82671C1-051F-4316-A08C-0EF141742489}">
|
||||
<File Id="filCCD77ADC0EAAE880C2F943B2F1A05EEF" KeyPath="yes" Source="$(var.xschemLibrarySrcDir)\ngspice\autozero_comp.sym" />
|
||||
</Component>
|
||||
<Component Id="cmp6459B0DD74A47A086E6B614933AFC28C" Guid="{84B8FE38-A121-4078-9118-E17E2FBB5879}">
|
||||
<File Id="fil407D827A4500F875A532804A7BE85429" KeyPath="yes" Source="$(var.xschemLibrarySrcDir)\ngspice\autozero_comp_xyce.sch" />
|
||||
</Component>
|
||||
|
|
@ -7192,6 +7195,7 @@
|
|||
<ComponentRef Id="cmp2088AAC35A08E0518ACDC24298104ED3" />
|
||||
<ComponentRef Id="cmp4E42D794E5F6CF3E7A3EDA9C016D70A3" />
|
||||
<ComponentRef Id="cmp81121000EE29EDB7D590EC4C84F1AA2A" />
|
||||
<ComponentRef Id="cmpD009418B633A058FED795DBEBEBC109A" />
|
||||
<ComponentRef Id="cmp6459B0DD74A47A086E6B614933AFC28C" />
|
||||
<ComponentRef Id="cmp89838BB57E0FD4179DCA4965EB90E8C7" />
|
||||
<ComponentRef Id="cmp80F17668356F715FB30000BA77553EBA" />
|
||||
|
|
|
|||
|
|
@ -3387,6 +3387,7 @@ void pan(int what, int mx, int my)
|
|||
* XCopy Area operations */
|
||||
void fix_restore_rect(double x1, double y1, double x2, double y2)
|
||||
{
|
||||
dbg(1, "%g %g %g %g\n", x1, y1, x2, y2);
|
||||
/* horizontal lines */
|
||||
MyXCopyAreaDouble(display, xctx->save_pixmap, xctx->window, xctx->gc[0],
|
||||
x1, y1, x2, y1, x1, y1,
|
||||
|
|
@ -3420,11 +3421,7 @@ void select_rect(int what, int select)
|
|||
}
|
||||
xctx->nl_xx1=xctx->nl_xr;xctx->nl_xx2=xctx->nl_xr2;xctx->nl_yy1=xctx->nl_yr;xctx->nl_yy2=xctx->nl_yr2;
|
||||
RECTORDER(xctx->nl_xx1,xctx->nl_yy1,xctx->nl_xx2,xctx->nl_yy2);
|
||||
if(fix_broken_tiled_fill || !_unix) {
|
||||
fix_restore_rect(xctx->nl_xx1,xctx->nl_yy1,xctx->nl_xx2,xctx->nl_yy2);
|
||||
} else {
|
||||
drawtemprect(xctx->gctiled,NOW, xctx->nl_xx1,xctx->nl_yy1,xctx->nl_xx2,xctx->nl_yy2);
|
||||
}
|
||||
drawtemprect(xctx->gctiled,NOW, xctx->nl_xx1,xctx->nl_yy1,xctx->nl_xx2,xctx->nl_yy2);
|
||||
xctx->nl_xr2=xctx->mousex_snap;xctx->nl_yr2=xctx->mousey_snap;
|
||||
|
||||
/* 20171026 update unselected objects while dragging */
|
||||
|
|
@ -3462,12 +3459,7 @@ void select_rect(int what, int select)
|
|||
else if(what & END)
|
||||
{
|
||||
RECTORDER(xctx->nl_xr,xctx->nl_yr,xctx->nl_xr2,xctx->nl_yr2);
|
||||
|
||||
if(fix_broken_tiled_fill || !_unix) {
|
||||
fix_restore_rect(xctx->nl_xr, xctx->nl_yr, xctx->nl_xr2, xctx->nl_yr2);
|
||||
} else {
|
||||
drawtemprect(xctx->gctiled, NOW, xctx->nl_xr,xctx->nl_yr,xctx->nl_xr2,xctx->nl_yr2);
|
||||
}
|
||||
drawtemprect(xctx->gctiled, NOW, xctx->nl_xr,xctx->nl_yr,xctx->nl_xr2,xctx->nl_yr2);
|
||||
if(xctx->nl_dir == 0) select_inside(xctx->nl_xr,xctx->nl_yr,xctx->nl_xr2,xctx->nl_yr2, xctx->nl_sel);
|
||||
else select_touch(xctx->nl_xr,xctx->nl_yr,xctx->nl_xr2,xctx->nl_yr2, xctx->nl_sel);
|
||||
|
||||
|
|
|
|||
|
|
@ -1800,8 +1800,11 @@ void drawtemprect(GC gc, int what, double rectx1,double recty1,double rectx2,dou
|
|||
if( rectclip(xctx->areax1,xctx->areay1,xctx->areax2,xctx->areay2,&x1,&y1,&x2,&y2) )
|
||||
{
|
||||
if((fix_broken_tiled_fill || !_unix) && gc == xctx->gctiled) {
|
||||
MyXCopyAreaDouble(display, xctx->save_pixmap, xctx->window, xctx->gc[0],
|
||||
rectx1, recty1, rectx2, recty2, rectx1, recty1, xctx->lw);
|
||||
/*
|
||||
* MyXCopyAreaDouble(display, xctx->save_pixmap, xctx->window, xctx->gc[0],
|
||||
* rectx1, recty1, rectx2, recty2, rectx1, recty1, xctx->lw);
|
||||
*/
|
||||
fix_restore_rect(rectx1, recty1, rectx2, recty2);
|
||||
|
||||
} else {
|
||||
XDrawRectangle(display, xctx->window, gc, (int)x1, (int)y1,
|
||||
|
|
|
|||
|
|
@ -86,7 +86,7 @@ proc inutile_alias_window {w filename} {
|
|||
toplevel $w -class Dialog
|
||||
wm title $w "(IN)UTILE ALIAS FILE: $filename"
|
||||
wm iconname $w "ALIAS"
|
||||
wm transient $w .
|
||||
# wm transient $w .
|
||||
|
||||
set fileid [open $filename "RDONLY CREAT"]
|
||||
set testo [read $fileid]
|
||||
|
|
@ -111,7 +111,7 @@ proc inutile_help_window {w filename} {
|
|||
toplevel $w -class Dialog
|
||||
wm title $w "(IN)UTILE ALIAS FILE"
|
||||
wm iconname $w "ALIAS"
|
||||
wm transient $w .
|
||||
# wm transient $w .
|
||||
|
||||
frame $w.buttons
|
||||
pack $w.buttons -side bottom -fill x -pady 2m
|
||||
|
|
@ -148,7 +148,7 @@ proc inutile { {filename {}}} {
|
|||
toplevel .inutile -class Dialog
|
||||
wm title .inutile "(IN)UTILE (Stefan Schippers, sschippe)"
|
||||
wm iconname .inutile "(IN)UTILE"
|
||||
wm transient .inutile .
|
||||
# wm transient .inutile .
|
||||
set utile_path $XSCHEM_SHAREDIR/utile
|
||||
set retval {}
|
||||
frame .inutile.buttons
|
||||
|
|
@ -451,7 +451,7 @@ proc list_running_cmds {} {
|
|||
set top .processlist
|
||||
if {[winfo exists $top]} {return}
|
||||
toplevel $top -class Dialog
|
||||
wm transient $top .
|
||||
# wm transient $top .
|
||||
set frame1 $top.f1
|
||||
set frame2 $top.f2
|
||||
set frame3 $top.f3
|
||||
|
|
@ -1318,7 +1318,7 @@ proc simconf {} {
|
|||
toplevel .sim -class Dialog
|
||||
wm title .sim {Simulation Configuration}
|
||||
wm geometry .sim 700x340
|
||||
wm transient .sim .
|
||||
# wm transient .sim .
|
||||
frame .sim.topf
|
||||
set scrollframe [sframe .sim.topf]
|
||||
frame ${scrollframe}.top
|
||||
|
|
@ -3152,7 +3152,7 @@ proc load_file_dialog {{msg {}} {ext {}} {global_initdir {INITIALINSTDIR}}
|
|||
if { $loadfile != 2} {xschem set semaphore [expr {[xschem get semaphore] +1}]}
|
||||
toplevel .load -class Dialog
|
||||
wm title .load $msg
|
||||
wm transient .load .
|
||||
# wm transient .load .
|
||||
set_ne myload_index1 0
|
||||
if { ![info exists myload_files1]} {
|
||||
set myload_files1 $pathlist
|
||||
|
|
@ -3876,7 +3876,7 @@ proc tclcmd {} {
|
|||
destroy .tclcmd
|
||||
}
|
||||
toplevel .tclcmd -class Dialog
|
||||
wm transient .tclcmd .
|
||||
# wm transient .tclcmd .
|
||||
label .tclcmd.txtlab -text {Enter TCL expression. Shift-Return will evaluate}
|
||||
panedwindow .tclcmd.p -orient vert
|
||||
text .tclcmd.t -width 100 -height 3
|
||||
|
|
@ -3997,6 +3997,7 @@ proc color_dim {} {
|
|||
|
||||
# show xschem about dialog
|
||||
proc about {} {
|
||||
global OS
|
||||
if [winfo exists .about] {
|
||||
bind .about.link <Button-1> {}
|
||||
bind .about.link2 <Button-1> {}
|
||||
|
|
@ -4023,10 +4024,17 @@ proc about {} {
|
|||
pack .about.descr
|
||||
pack .about.copyright
|
||||
pack .about.close
|
||||
bind .about.link <Button-1> {execute 0 xdg-open http://repo.hu/projects/xschem}
|
||||
bind .about.link2 <Button-1> {execute 0 xdg-open https://github.com/StefanSchippers/xschem}
|
||||
bind .about.link3 <Button-1> {execute 0 xdg-open http://repo.hu/projects/xschem/index.html}
|
||||
bind .about.link4 <Button-1> {execute 0 xdg-open file://$XSCHEM_SHAREDIR/../doc/xschem/xschem_man/xschem_man.html}
|
||||
if {$OS == "Windows"} {
|
||||
bind .about.link <Button-1> {eval start http://repo.hu/projects/xschem}
|
||||
bind .about.link2 <Button-1> {eval start https://github.com/StefanSchippers/xschem}
|
||||
bind .about.link3 <Button-1> {eval start http://repo.hu/projects/xschem/index.html}
|
||||
bind .about.link4 <Button-1> {eval start $XSCHEM_SHAREDIR/../doc/xschem/xschem_man/xschem_man.html}
|
||||
} else {
|
||||
bind .about.link <Button-1> {execute 0 xdg-open http://repo.hu/projects/xschem}
|
||||
bind .about.link2 <Button-1> {execute 0 xdg-open https://github.com/StefanSchippers/xschem}
|
||||
bind .about.link3 <Button-1> {execute 0 xdg-open http://repo.hu/projects/xschem/index.html}
|
||||
bind .about.link4 <Button-1> {execute 0 xdg-open file://$XSCHEM_SHAREDIR/../doc/xschem/xschem_man/xschem_man.html}
|
||||
}
|
||||
}
|
||||
|
||||
proc property_search {} {
|
||||
|
|
@ -4919,7 +4927,7 @@ proc textwindow {filename {ro {}}} {
|
|||
toplevel $textwindow_w
|
||||
wm title $textwindow_w $filename
|
||||
wm iconname $textwindow_w $filename
|
||||
wm transient $textwindow_w .
|
||||
# wm transient $textwindow_w .
|
||||
frame $textwindow_w.buttons
|
||||
pack $textwindow_w.buttons -side bottom -fill x -pady 2m
|
||||
button $textwindow_w.buttons.dismiss -text Dismiss -command "destroy $textwindow_w"
|
||||
|
|
@ -4965,7 +4973,7 @@ proc viewdata {data {ro {}} {win .view}} {
|
|||
set rcode {}
|
||||
toplevel $viewdata_w
|
||||
wm title $viewdata_w {View data}
|
||||
wm transient $viewdata_w .
|
||||
# wm transient $viewdata_w .
|
||||
frame $viewdata_w.buttons
|
||||
pack $viewdata_w.buttons -side bottom -fill x -pady 2m
|
||||
|
||||
|
|
@ -5592,7 +5600,7 @@ proc context_menu { } {
|
|||
}
|
||||
|
||||
proc tab_ctx_cmd {tab_but what} {
|
||||
global terminal editor netlist_dir
|
||||
global terminal editor netlist_dir OS
|
||||
# get win_path from tab name
|
||||
set win_path [lindex [$tab_but cget -command] 3] ;# xschem new_schematic switch .x1.drw
|
||||
set tablist [xschem tab_list]
|
||||
|
|
@ -5606,20 +5614,43 @@ proc tab_ctx_cmd {tab_but what} {
|
|||
if {!$found} { set filename {}}
|
||||
if { $filename ne {} } {
|
||||
if {$what eq {dir}} {
|
||||
execute 0 xdg-open [file dirname $filename]
|
||||
if {$OS == "Windows" } {
|
||||
set dir [file dirname $filename]
|
||||
set command [list {*}[auto_execok start] {}]
|
||||
exec {*}$command $dir &
|
||||
} else {
|
||||
execute 0 xdg-open [file dirname $filename]
|
||||
}
|
||||
} elseif {$what eq {copy}} {
|
||||
clipboard clear
|
||||
clipboard append $filename
|
||||
} elseif {$what eq {term}} {
|
||||
set save [pwd]
|
||||
cd [file dirname $filename]
|
||||
execute 0 $terminal
|
||||
cd $save
|
||||
if {$OS == "Windows" } {
|
||||
set save [pwd]
|
||||
set dir [file dirname $filename]
|
||||
cd $dir
|
||||
set command [list {*}[auto_execok start] {}]
|
||||
exec {*}$command &
|
||||
cd $save
|
||||
} else {
|
||||
set save [pwd]
|
||||
cd [file dirname $filename]
|
||||
execute 0 $terminal
|
||||
cd $save
|
||||
}
|
||||
} elseif {$what eq {simterm}} {
|
||||
set save [pwd]
|
||||
cd $netlist_dir
|
||||
execute 0 $terminal
|
||||
cd $save
|
||||
if {$OS == "Windows" } {
|
||||
set save [pwd]
|
||||
cd $netlist_dir
|
||||
set command [list {*}[auto_execok start] {}]
|
||||
exec {*}$command &
|
||||
cd $save
|
||||
} else {
|
||||
set save [pwd]
|
||||
cd $netlist_dir
|
||||
execute 0 $terminal
|
||||
cd $save
|
||||
}
|
||||
} elseif {$what eq {edit}} {
|
||||
eval execute 0 $editor $filename
|
||||
} elseif {$what eq {netlist}} {
|
||||
|
|
@ -5713,7 +5744,7 @@ proc tab_context_menu {tab_but} {
|
|||
-font [subst $font] \
|
||||
-command "
|
||||
set retval 6
|
||||
xschem new_schematic create {} $counterpart
|
||||
xschem new_schematic create {} {$counterpart}
|
||||
destroy .ctxmenu
|
||||
"
|
||||
}
|
||||
|
|
@ -7422,7 +7453,11 @@ set_ne editor {gvim -f}
|
|||
set_ne rainbow_colors 0
|
||||
set_ne initial_geometry {900x600}
|
||||
set_ne edit_symbol_prop_new_sel {}
|
||||
set_ne launcher_default_program {xdg-open}
|
||||
if {$OS == "Windows"} {
|
||||
set_ne launcher_default_program {start}
|
||||
} else {
|
||||
set_ne launcher_default_program {xdg-open}
|
||||
}
|
||||
set_ne auto_hilight 0
|
||||
set_ne use_tclreadline 1
|
||||
set_ne en_hilight_conn_inst 0
|
||||
|
|
@ -7494,7 +7529,7 @@ set_ne dark_colorscheme 1
|
|||
set_ne enable_dim_bg 0
|
||||
set_ne dim_bg 0.0
|
||||
set_ne dim_value 0.0
|
||||
set_ne fix_broken_tiled_fill 0 ;# set to 1 on some broken X11 drivers / GPUs that show garbage on screen */
|
||||
set_ne fix_broken_tiled_fill 1 ;# set to 1 on some broken X11 drivers / GPUs that show garbage on screen */
|
||||
# this fix uses an alternative method for getting mouse coordinates on KeyPress/KeyRelease
|
||||
# events. Some remote connection softwares do not generate the correct coordinates
|
||||
# on such events */
|
||||
|
|
|
|||
Loading…
Reference in New Issue