Compare commits
14 Commits
d7d1a95215
...
63cd6f0ac8
Author | SHA1 | Date | |
---|---|---|---|
63cd6f0ac8 | |||
4fcc17675c | |||
4e903ce12b | |||
bfdb42c91f | |||
55d641b0da | |||
0e7cff0715 | |||
4d30fd7a2b | |||
292bd1d739 | |||
1a756358f5 | |||
009c0d0519 | |||
bab6267412 | |||
72196f42de | |||
f1e958af41 | |||
|
78de535233 |
@@ -28,6 +28,8 @@ jobs:
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
fetch-depth: 0
|
||||
|
||||
- name: Get describe
|
||||
id: vars
|
||||
@@ -77,6 +79,7 @@ jobs:
|
||||
- name: Build and install kerpack
|
||||
if: steps.cache-toolchain.outputs.cache-hit != 'true'
|
||||
run: |
|
||||
export PATH=/home/autobuild/tools/win32/bin:$PATH
|
||||
cd ${{ gitea.workspace }}/programs/other/kpack/kerpack_linux/
|
||||
make
|
||||
chmod +x kerpack
|
||||
@@ -85,6 +88,7 @@ jobs:
|
||||
- name: Build and install kpack
|
||||
if: steps.cache-toolchain.outputs.cache-hit != 'true'
|
||||
run: |
|
||||
export PATH=/home/autobuild/tools/win32/bin:$PATH
|
||||
cd ${{ gitea.workspace }}/programs/other/kpack/linux/
|
||||
bash build.sh
|
||||
chmod +x kpack
|
||||
@@ -144,6 +148,7 @@ jobs:
|
||||
- name: (en_US) Build KolibriOS
|
||||
run: |
|
||||
export PATH=/home/autobuild/tools/win32/bin:$PATH
|
||||
source kos32-export-env-vars ${{ gitea.workspace }}
|
||||
tup build-en_US
|
||||
|
||||
- name: (en_US) Upload floppy image
|
||||
@@ -168,6 +173,7 @@ jobs:
|
||||
- name: (ru_RU) Build KolibriOS
|
||||
run: |
|
||||
export PATH=/home/autobuild/tools/win32/bin:$PATH
|
||||
source kos32-export-env-vars ${{ gitea.workspace }}
|
||||
tup build-ru_RU
|
||||
|
||||
- name: (ru_RU) Upload floppy image
|
||||
@@ -192,6 +198,7 @@ jobs:
|
||||
- name: (es_ES) Build KolibriOS
|
||||
run: |
|
||||
export PATH=/home/autobuild/tools/win32/bin:$PATH
|
||||
source kos32-export-env-vars ${{ gitea.workspace }}
|
||||
tup build-es_ES
|
||||
|
||||
- name: (es_ES) Upload floppy image
|
||||
|
@@ -890,10 +890,6 @@ for i,v in ipairs(img_files) do
|
||||
str = string.gsub(str, "%%", "%%%%") -- escape % as %%
|
||||
cmd += " && str=" .. str
|
||||
cmd += ' && echo -n $str | dd status=none of=%o bs=1 seek=`expr 274 - length "$str"` conv=notrunc'
|
||||
str2='$(get-current-cmtid|grep -oE "\\+[0-9]+")'
|
||||
str2 = string.gsub(str2, "%$", "\\$") -- escape $ as \$
|
||||
cmd += " && str2=" .. str2
|
||||
cmd += ' && echo -n $str2 | dd status=none of=%o bs=1 seek=216 conv=notrunc'
|
||||
end
|
||||
local_file = VAR_KERNEL .. "/.kernel.mnt"
|
||||
tup.definerule{inputs = {v[2]}, command = cmd, outputs = {local_file}}
|
||||
|
@@ -3,10 +3,25 @@ HELPERDIR = (tup.getconfig("HELPERDIR") == "") and "../../programs" or tup.getco
|
||||
tup.include(HELPERDIR .. "/use_fasm.lua")
|
||||
add_include(tup.getvariantdir())
|
||||
|
||||
-- environment variables
|
||||
tup.import("KOLIBRIOS_BUILD_OFFSET") -- 1234
|
||||
tup.import("KOLIBRIOS_BUILD_CMTID") -- 0xaabbccdd
|
||||
tup.import("KOLIBRIOS_BUILD_DBGTAG") -- 0x61 for 'a', etc
|
||||
|
||||
str_build = ""
|
||||
if KOLIBRIOS_BUILD_OFFSET then
|
||||
str_build += " -dBUILD_OFFSET=" .. KOLIBRIOS_BUILD_OFFSET
|
||||
end
|
||||
if KOLIBRIOS_BUILD_CMTID then
|
||||
str_build += " -dBUILD_CMTID=" .. KOLIBRIOS_BUILD_CMTID
|
||||
end
|
||||
if KOLIBRIOS_BUILD_DBGTAG then
|
||||
str_build += " -dBUILD_DBGTAG=" .. KOLIBRIOS_BUILD_DBGTAG
|
||||
end
|
||||
|
||||
tup.rule("echo lang fix " .. ((tup.getconfig("LANG") == "") and "en_US" or tup.getconfig("LANG")) .. " > %o", {"lang.inc"})
|
||||
tup.rule({"kernel.asm", extra_inputs = {"lang.inc"}}, FASM .. " -m 262144 %f %o " .. tup.getconfig("KERPACK_CMD"), "kernel.mnt")
|
||||
--tup.rule({"kernel.asm", extra_inputs = {"lang.inc"}}, FASM .. " -m 262144 %f %o -s %o.fas" .. tup.getconfig("KERPACK_CMD"), {"kernel.mnt", extra_outputs = {"kernel.mnt.fas"}})
|
||||
tup.rule({"kernel.asm", extra_inputs = {"lang.inc"}}, FASM .. " -m 262144 %f %o -s %o.fas" .. str_build .. tup.getconfig("KERPACK_CMD"), {"kernel.mnt", extra_outputs = {"kernel.mnt.fas"}})
|
||||
--tup.rule({"kernel.mnt.fas", extra_inputs = {"kernel.mnt"}}, "symbols %f %o", "kernel.mnt.sym")
|
||||
--tup.rule({"kernel.mnt.fas", extra_inputs = {"kernel.mnt"}}, "listing %f %o", "kernel.mnt.lst")
|
||||
tup.rule({"kernel.asm", extra_inputs = {"lang.inc"}}, FASM .. " -m 262144 %f %o -dextended_primary_loader=1" .. tup.getconfig("KERPACK_CMD"), "kernel.mnt.ext_loader")
|
||||
tup.rule({"kernel.asm", extra_inputs = {"lang.inc"}}, FASM .. " -m 262144 %f %o -dpretest_build=1 -ddebug_com_base=0xe9", "kernel.mnt.pretest")
|
||||
tup.rule({"kernel.asm", extra_inputs = {"lang.inc"}}, FASM .. " -m 262144 %f %o " .. str_build .. " -dextended_primary_loader=1 " .. tup.getconfig("KERPACK_CMD"), "kernel.mnt.ext_loader")
|
||||
tup.rule({"kernel.asm", extra_inputs = {"lang.inc"}}, FASM .. " -m 262144 %f %o " .. str_build .. " -dpretest_build=1 -ddebug_com_base=0xe9", "kernel.mnt.pretest")
|
||||
|
@@ -28,36 +28,42 @@ macro line_space {
|
||||
db 186
|
||||
}
|
||||
d80x25_top:
|
||||
line_full_top
|
||||
if __REV__ > 0
|
||||
line_full_top
|
||||
; draw seven digits of the git hash
|
||||
__x = BUILD_CMTID
|
||||
if __x > 0
|
||||
__x = __x SHR 4
|
||||
cur_line_pos = 75
|
||||
store byte ' ' at d80x25_top+cur_line_pos+1
|
||||
rev_var = __REV__
|
||||
while rev_var > 0
|
||||
store byte rev_var mod 10 + '0' at d80x25_top+cur_line_pos
|
||||
cur_line_pos = cur_line_pos - 1
|
||||
rev_var = rev_var / 10
|
||||
end while
|
||||
store byte ' ' at d80x25_top+cur_line_pos
|
||||
store dword ' SVN' at d80x25_top+cur_line_pos-4
|
||||
store byte ' ' at d80x25_top+cur_line_pos+1
|
||||
repeat 7
|
||||
digit = __x AND 0xf
|
||||
if digit > 9
|
||||
digit = digit - 10 + 'a'
|
||||
else
|
||||
digit = digit + '0'
|
||||
end if
|
||||
store byte digit at d80x25_top+cur_line_pos
|
||||
cur_line_pos = cur_line_pos - 1
|
||||
__x = __x SHR 4
|
||||
end repeat
|
||||
store byte ' ' at d80x25_top+cur_line_pos
|
||||
store dword ' GIT' at d80x25_top+cur_line_pos-4
|
||||
end if
|
||||
|
||||
space_msg:
|
||||
line_space
|
||||
line_space
|
||||
verstr:
|
||||
; line_space
|
||||
; version string
|
||||
db 186,32
|
||||
repeat 78
|
||||
load a byte from kernel_header.signature+%-1
|
||||
if a = 13
|
||||
break
|
||||
end if
|
||||
db a
|
||||
end repeat
|
||||
repeat 78 - ($-verstr)
|
||||
db ' '
|
||||
end repeat
|
||||
db 32,186
|
||||
line_half
|
||||
db 186,32
|
||||
repeat 78
|
||||
load a byte from kernel_header.signature+%-1
|
||||
if a = 13
|
||||
break
|
||||
end if
|
||||
db a
|
||||
end repeat
|
||||
repeat 78 - ($-verstr)
|
||||
db ' '
|
||||
end repeat
|
||||
db 32,186
|
||||
line_half
|
||||
d80x25_top_num = 4
|
||||
|
@@ -24,9 +24,38 @@ org 0
|
||||
; struct kernel_header
|
||||
jmp start_of_code ; jump
|
||||
db 'KolibriOS ' ; signature
|
||||
db 'v0.7.7.0 ',13,10,13,10,0 ; FIXME: get distribution version from git tag
|
||||
db 'v0.7.7.0' ; FIXME: get distribution version from git tag?
|
||||
.offset db ' ',13,10,0
|
||||
dd B32-KERNEL_BASE ; offset of the kernel's 32-bit entry point
|
||||
|
||||
cur_line_pos = 0
|
||||
offset_len = 0
|
||||
__x = BUILD_OFFSET
|
||||
if __x > 0
|
||||
store byte '+' at .offset+cur_line_pos
|
||||
if __x < 10
|
||||
offset_len = 2 ; '+' and a digit
|
||||
else if __x < 100
|
||||
offset_len = 3
|
||||
else if __x < 1000
|
||||
offset_len = 4
|
||||
else if __x < 10000
|
||||
offset_len = 5
|
||||
else
|
||||
offset_len = 6
|
||||
end if
|
||||
cur_line_pos = cur_line_pos + offset_len - 1
|
||||
while __x > 0
|
||||
store byte __x mod 10 + '0' at .offset+cur_line_pos
|
||||
cur_line_pos = cur_line_pos - 1
|
||||
__x = __x / 10
|
||||
end while
|
||||
end if
|
||||
if BUILD_DBGTAG > 0
|
||||
store byte '-' at .offset+offset_len
|
||||
store byte BUILD_DBGTAG at .offset+offset_len+1
|
||||
end if
|
||||
|
||||
include "boot/bootstr.inc" ; language-independent boot messages
|
||||
include "boot/preboot.inc"
|
||||
|
||||
|
@@ -227,6 +227,33 @@ struct kernel_header
|
||||
; KERNEL.MNT file can be booted on BIOS as well as on UEFI.
|
||||
ends
|
||||
|
||||
struct kernel_version
|
||||
; OS release number, e.g. 0,7,7,0. Distro-specific.
|
||||
osrel rb 4
|
||||
; A single char like 'a' to append to the version, or 0 to omit it.
|
||||
; 0 means 0.7.7.0+1234, 'a' means 0.7.7.0+1234-a, etc.
|
||||
; This allows developers to determine the debug build by its log.
|
||||
; Unfortunately, users sometimes mess things and test not the build they
|
||||
; were asked to test.
|
||||
dbgtag db ?
|
||||
; The kernel itself doesn't have any version other than its ABI version.
|
||||
; The minor and major parts were meant to mean significant compatible
|
||||
; and incompatible changes correspondingly. It is for a developer to
|
||||
; decide on what is a significant change.
|
||||
abimin db ?
|
||||
; The major ABI version must be at least 0x28 for backward compatibility
|
||||
; with the old revision number: 0x2800 = 10240 > the last SVN revision.
|
||||
abimaj dw ?
|
||||
; In binary, e.g. a short git hash. A single dword is 8 digits which
|
||||
; should be enough for the foreseeable future. We always can get space
|
||||
; for four more digits from the two reserved bytes below if needed.
|
||||
cmtid dd ?
|
||||
reserved dw ?
|
||||
; The number of commits from the last release.
|
||||
offset dw ?
|
||||
ends
|
||||
assert sizeof.kernel_version = 16
|
||||
|
||||
DRIVE_DATA_SIZE = 16
|
||||
|
||||
OS_BASE = 0x80000000
|
||||
|
@@ -970,13 +970,21 @@ picture rb Xsize*Ysize*4 ; 32 бита
|
||||
размером 16 байт для будущей совместимости, в будущем могут быть
|
||||
добавлены некоторые поля.
|
||||
Структура буфера:
|
||||
db a,b,c,d для версии a.b.c.d
|
||||
db 0: зарезервировано
|
||||
dd REV - номер svn-ревизии ядра
|
||||
Для ядра Kolibri 0.7.7.0+:
|
||||
db a,b,c,d для версии ОС a.b.c.d
|
||||
db отладочная метка, для релиза всегда 0, иначе любой символ ASCII
|
||||
db младшая часть ABI ядра
|
||||
dw старшая часть ABI ядра
|
||||
dd идентификатор коммита, например краткий git-хэш в бинарном виде
|
||||
dw зарезервировано
|
||||
dw количество коммитов с момента последнего релиза
|
||||
Пример структуры для ядра Kolibri 0.7.7.0+:
|
||||
db 0,7,7,0
|
||||
db 0
|
||||
dd 1675
|
||||
db 0
|
||||
dw 40
|
||||
dd 0xf26d5b28
|
||||
dw 0
|
||||
dw 1675
|
||||
|
||||
---------------------- Константы для регистров: ----------------------
|
||||
eax - SF_SYSTEM (18)
|
||||
|
@@ -962,13 +962,21 @@ Remarks:
|
||||
16 byte buffer for the future compatibility, in the future
|
||||
some fields can be added.
|
||||
Structure of the buffer:
|
||||
db a,b,c,d for version a.b.c.d
|
||||
db 0: reserved
|
||||
dd REV - kernel SVN revision number
|
||||
For Kolibri 0.7.7.0+ kernel:
|
||||
db a,b,c,d for os version a.b.c.d
|
||||
db debug tag, 0 for release, any ASCII char otherwise
|
||||
db kernel ABI minor
|
||||
dw kernel ABI major
|
||||
dd commit id, e.g. short git hash in binary
|
||||
dw reserved
|
||||
dw the number of commits since the latest release
|
||||
For Kolibri 0.7.7.0+ the structure is like this:
|
||||
db 0,7,7,0
|
||||
db 0
|
||||
dd 1675
|
||||
db 0
|
||||
dw 40
|
||||
dd 0xf26d5b28
|
||||
dw 0
|
||||
dw 1675
|
||||
|
||||
---------------------- Constants for registers: ----------------------
|
||||
eax - SF_SYSTEM (18)
|
||||
|
@@ -30,6 +30,8 @@ format binary as "mnt"
|
||||
include 'macros.inc'
|
||||
include 'struct.inc'
|
||||
|
||||
ABI_MAJOR = 0x28
|
||||
ABI_MINOR = 0
|
||||
|
||||
USE_COM_IRQ = 1 ; make irq 3 and irq 4 available for PCI devices
|
||||
VESA_1_2_VIDEO = 0 ; enable vesa 1.2 bank switch functions
|
||||
@@ -711,10 +713,33 @@ end if
|
||||
|
||||
|
||||
;-----------------------------------------------------------------------------
|
||||
; show SVN version of kernel on the message board
|
||||
; show OS version, offset, debug tag and commit id on the message board
|
||||
;-----------------------------------------------------------------------------
|
||||
mov eax, [version_inf.rev]
|
||||
DEBUGF 1, "K : kernel SVN r%d\n", eax
|
||||
mov eax, version_inf.osrel
|
||||
DEBUGF 1, "K : OS version: %u.%u.%u.%u", [eax+0]:1, [eax+1]:1, \
|
||||
[eax+2]:1, [eax+3]:1, ecx
|
||||
movzx ecx, [version_inf.offset]
|
||||
jecxz @f
|
||||
DEBUGF 1, "+%u", ecx
|
||||
@@:
|
||||
movzx ecx, [version_inf.dbgtag]
|
||||
jecxz @f
|
||||
push ecx
|
||||
mov ecx, esp
|
||||
DEBUGF 1, "-%s", ecx
|
||||
pop ecx
|
||||
@@:
|
||||
DEBUGF 1, "\n"
|
||||
mov ecx, [version_inf.cmtid]
|
||||
jecxz @f
|
||||
DEBUGF 1, "K : Commit ID: %x\n", ecx
|
||||
@@:
|
||||
;-----------------------------------------------------------------------------
|
||||
; show kernel ABI
|
||||
;-----------------------------------------------------------------------------
|
||||
movzx eax, [version_inf.abimaj]
|
||||
movzx ecx, [version_inf.abimin]
|
||||
DEBUGF 1, "K : Kernel ABI: %u.%u\n", eax, ecx
|
||||
;-----------------------------------------------------------------------------
|
||||
; show CPU count on the message board
|
||||
;-----------------------------------------------------------------------------
|
||||
@@ -2102,12 +2127,12 @@ sysfn_getdiskinfo: ; 18.11 = get disk info table
|
||||
;------------------------------------------------------------------------------
|
||||
sysfn_getversion: ; 18.13 = get kernel ID and version
|
||||
; if given memory address belongs to kernel then error
|
||||
stdcall is_region_userspace, ecx, version_inf.size
|
||||
stdcall is_region_userspace, ecx, sizeof.kernel_version
|
||||
jnz .addr_error
|
||||
|
||||
mov edi, ecx
|
||||
mov esi, version_inf
|
||||
mov ecx, version_inf.size
|
||||
mov ecx, sizeof.kernel_version
|
||||
rep movsb
|
||||
ret
|
||||
.addr_error: ; if given memory address is illegal
|
||||
@@ -2287,11 +2312,18 @@ sound_flag db 0
|
||||
endg
|
||||
|
||||
iglobal
|
||||
version_inf:
|
||||
db 0,7,7,0 ; FIXME: Get distribution version from git tag
|
||||
db 0
|
||||
.rev dd __REV__
|
||||
.size = $ - version_inf
|
||||
if ~ definite BUILD_DBGTAG
|
||||
BUILD_DBGTAG = 0
|
||||
end if
|
||||
if ~ definite BUILD_CMTID
|
||||
BUILD_CMTID = 0
|
||||
end if
|
||||
if ~ definite BUILD_OFFSET
|
||||
BUILD_OFFSET = 0
|
||||
end if
|
||||
align 4
|
||||
version_inf kernel_version <0,7,7,0>, BUILD_DBGTAG, ABI_MINOR, ABI_MAJOR, \
|
||||
BUILD_CMTID, 0, BUILD_OFFSET
|
||||
endg
|
||||
;------------------------------------------------------------------------------
|
||||
align 4
|
||||
@@ -4457,8 +4489,6 @@ end if
|
||||
|
||||
include "data32.inc"
|
||||
|
||||
__REV__ = __REV
|
||||
|
||||
if ~ lang eq es_ES
|
||||
diff16 "end of kernel code",0,$
|
||||
end if
|
||||
|
@@ -5,16 +5,6 @@
|
||||
;; ;;
|
||||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||
|
||||
__REV = 0
|
||||
|
||||
macro $Revision a {
|
||||
match =: Num =$,a \{
|
||||
if __REV < Num
|
||||
__REV = Num
|
||||
end if
|
||||
\}
|
||||
}
|
||||
|
||||
;// mike.dld, 2006-29-01 [
|
||||
|
||||
; macros definition
|
||||
|
@@ -68,6 +68,7 @@ struct TWebBrowser {
|
||||
void tag_a();
|
||||
void tag_p();
|
||||
void tag_img();
|
||||
void tag_kosicon();
|
||||
void tag_div();
|
||||
void tag_h1234_caption();
|
||||
void tag_ol_ul_dt();
|
||||
@@ -176,7 +177,7 @@ void TWebBrowser::ParseHtml(dword _bufpointer, _bufsize){
|
||||
}
|
||||
}
|
||||
if (ESBYTE[bufpos] == '&') {
|
||||
bufpos = GetUnicodeSymbol(#linebuf, sizeof(TWebBrowser.linebuf), bufpos+1, bufpointer+bufsize);
|
||||
bufpos = GetUnicodeSymbol(#linebuf, sizeof(TWebBrowser.linebuf)-1, bufpos+1, bufpointer+bufsize);
|
||||
continue;
|
||||
}
|
||||
if (ESBYTE[bufpos] == '<') && (is_html) {
|
||||
|
@@ -67,7 +67,7 @@ bool _tag::parse(dword _bufpos, bufend)
|
||||
|
||||
if (!whitepos) || (whitepos > closepos) {
|
||||
//no param
|
||||
strncpy(#name, bufpos, math.min(closepos - bufpos, sizeof(tag.name)));
|
||||
strncpy(#name, bufpos, math.min(closepos - bufpos, sizeof(tag.name)-1));
|
||||
bufpos = closepos;
|
||||
} else {
|
||||
//we have param
|
||||
@@ -76,7 +76,7 @@ bool _tag::parse(dword _bufpos, bufend)
|
||||
if (openpos < strchr(closepos+1, '>')) break;
|
||||
if (!closepos = EAX) {closepos = bufend;break;}
|
||||
}
|
||||
strncpy(#name, bufpos, math.min(whitepos - bufpos, sizeof(tag.name)));
|
||||
strncpy(#name, bufpos, math.min(whitepos - bufpos, sizeof(tag.name)-1));
|
||||
bufpos = closepos;
|
||||
|
||||
params = malloc(closepos - whitepos + 1);
|
||||
|
@@ -151,7 +151,7 @@ bool TWebBrowser::RenderImage(dword cur_img)
|
||||
int img_x, img_y, img_w, img_h;
|
||||
dword imgbuf[44];
|
||||
|
||||
if (!cur_img) return false;
|
||||
if (!cur_img) || (!buf_data) return false;
|
||||
|
||||
img_h = ESDWORD[cur_img+8];
|
||||
img_w = ESDWORD[cur_img+4];
|
||||
|
@@ -10,6 +10,7 @@ void TWebBrowser::SetStyle()
|
||||
if (tag.is("a")) { tag_a(); return; }
|
||||
if (tag.is("p")) { tag_p(); return; }
|
||||
if (tag.is("img")) { tag_img(); return; }
|
||||
if (tag.is("kosicon")) { tag_kosicon(); return; }
|
||||
if (tag.is("div")) { tag_div(); return; }
|
||||
if (tag.is("br")) { /*draw_x++;*/NewLine(); return; }
|
||||
if (tag.is("nav")) { style.nav = tag.opened; return; }
|
||||
@@ -266,6 +267,17 @@ void TWebBrowser::tag_h1234_caption()
|
||||
}
|
||||
}
|
||||
|
||||
void TWebBrowser::tag_kosicon()
|
||||
{
|
||||
dword imgbuf[44];
|
||||
dword shared_i18 = memopen("ICONS18", NULL, SHM_READ);
|
||||
if (shared_i18) && (tag.get_number_of("n")) {
|
||||
if (draw_x + 18 > canvas.bufw) NewLine();
|
||||
canvas.DrawImage(draw_x, draw_y-2, 18, 18, 18*18*4*tag.number+shared_i18);
|
||||
draw_x += 22;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
void TWebBrowser::tag_img()
|
||||
{
|
||||
@@ -305,7 +317,7 @@ void TWebBrowser::tag_img()
|
||||
img_decode stdcall (cache.current_buf, cache.current_size, 0);
|
||||
if (EAX) goto IMGOK; else goto NOIMG;
|
||||
} else {
|
||||
img_url.add(#img_path);
|
||||
if (img_url.get_pos_by_name(#img_path)==-1) img_url.add(#img_path);
|
||||
goto NOIMG;
|
||||
}
|
||||
|
||||
@@ -453,9 +465,10 @@ void TWebBrowser::tag_table()
|
||||
}
|
||||
if (table.cols.get(tr_pos-1)-td_pos>1) && (tag.get_number_of("width")) {
|
||||
if (strchr(tag.value, '%')) {
|
||||
tag.number = cur_cell_w - table.margin - 23 - left_gap * tag.number / 100;
|
||||
tag.number = cur_cell_w * tag.number / 100; //
|
||||
}
|
||||
if (tag.number < draw_w) draw_w = tag.number;
|
||||
if (tag.number < list.w - table.margin - left_gap) draw_w = tag.number;
|
||||
|
||||
}
|
||||
draw_y = row_start_y;
|
||||
td_pos++;
|
||||
|
@@ -66,6 +66,7 @@ char *unicode_symbols[]={
|
||||
"lowast","*",
|
||||
|
||||
"#128154","<3",
|
||||
"#128545",":(",
|
||||
|
||||
0};
|
||||
|
||||
|
@@ -79,7 +79,7 @@ char default_dir[] = "/sys";
|
||||
od_filter filter2 = { 22, "TXT\0HTM\0HTML\0DOCX\0\0" };
|
||||
|
||||
char editURL[URL_SIZE+1];
|
||||
edit_box omnibox_edit = {, 0, 0, 0xffffff,
|
||||
edit_box omnibox_edit = {250, 0, 0, 0xffffff,
|
||||
0x94AECE, 0xffffff, 0xffffff,0x10000000,URL_SIZE-2,#editURL,0,,19,19};
|
||||
|
||||
//===================================================//
|
||||
@@ -199,7 +199,7 @@ void main()
|
||||
GetProcessInfo(#Form, SelfInfo);
|
||||
ProcessMenuClick();
|
||||
sc.get();
|
||||
if (Form.status_window>2) break;
|
||||
if (Form.status_window & ROLLED_UP) break;
|
||||
if (Form.height<120) { MoveSize(OLD,OLD,OLD,120); break; }
|
||||
if (Form.width<280) { MoveSize(OLD,OLD,280,OLD); break; }
|
||||
draw_window();
|
||||
@@ -258,6 +258,7 @@ void main()
|
||||
free(http.content_pointer);
|
||||
GetImg(false);
|
||||
}
|
||||
debugln("end evNetwork");
|
||||
}
|
||||
break;
|
||||
default:
|
||||
@@ -516,7 +517,6 @@ bool GetLocalFileData(dword _path)
|
||||
bool GetUrl(dword _http_url)
|
||||
{
|
||||
char new_url_full[URL_SIZE+1];
|
||||
|
||||
if (!strncmp(_http_url,"http:",5)) {
|
||||
http.get(_http_url);
|
||||
return true;
|
||||
@@ -571,10 +571,10 @@ void OpenPage(dword _open_URL)
|
||||
//INTERNAL PAGE
|
||||
history.add(#new_url);
|
||||
WB1.custom_encoding = -1;
|
||||
if (streq(#new_url, URL_SERVICE_HOMEPAGE)) LoadInternalPage(#buildin_page_home, sizeof(buildin_page_home));
|
||||
else if (streq(#new_url, URL_SERVICE_TEST)) LoadInternalPage(#buildin_page_test, sizeof(buildin_page_test));
|
||||
if (streq(#new_url, URL_SERVICE_HOMEPAGE)) LoadInternalPage(#buildin_page_home, sizeof(buildin_page_home)-1);
|
||||
else if (streq(#new_url, URL_SERVICE_TEST)) LoadInternalPage(#buildin_page_test, sizeof(buildin_page_test)-1);
|
||||
else if (streq(#new_url, URL_SERVICE_HISTORY)) ShowHistory();
|
||||
else LoadInternalPage(#buildin_page_error, sizeof(buildin_page_error));
|
||||
else LoadInternalPage(#buildin_page_error, sizeof(buildin_page_error)-1);
|
||||
|
||||
} else if (!strncmp(#new_url,"http:",5)) || (!strncmp(#new_url,"https:",6)) {
|
||||
//WEB PAGE
|
||||
@@ -589,7 +589,7 @@ void OpenPage(dword _open_URL)
|
||||
|
||||
if (!http.transfer) {
|
||||
history.add(#new_url);
|
||||
LoadInternalPage(#buildin_page_error, sizeof(buildin_page_error));
|
||||
LoadInternalPage(#buildin_page_error, sizeof(buildin_page_error)-1);
|
||||
}
|
||||
} else {
|
||||
//LOCAL PAGE
|
||||
@@ -602,7 +602,7 @@ void OpenPage(dword _open_URL)
|
||||
strcpy(#new_url, "/tmp0/1/temp/word/document.xml");
|
||||
}
|
||||
if (!GetLocalFileData(#new_url)) {
|
||||
LoadInternalPage(#buildin_page_error, sizeof(buildin_page_error));
|
||||
LoadInternalPage(#buildin_page_error, sizeof(buildin_page_error)-1);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -712,7 +712,7 @@ void EventSubmitOmnibox()
|
||||
|
||||
void LoadInternalPage(dword _bufdata, _in_bufsize){
|
||||
if (!_bufdata) || (!_in_bufsize) {
|
||||
LoadInternalPage(#buildin_page_error, sizeof(buildin_page_error));
|
||||
LoadInternalPage(#buildin_page_error, sizeof(buildin_page_error)-1);
|
||||
} else {
|
||||
WB1.list.first = 0; //scroll page to the top
|
||||
DrawOmnibox();
|
||||
@@ -870,7 +870,7 @@ void DrawStatusBar(dword _msg)
|
||||
{
|
||||
dword status_y = Form.cheight - STATUSBAR_H + 4;
|
||||
dword status_w = Form.cwidth - 90;
|
||||
if (Form.status_window>2) return;
|
||||
if (Form.status_window & ROLLED_UP) return;
|
||||
DrawBar(0,Form.cheight - STATUSBAR_H+1, Form.cwidth,STATUSBAR_H-1, sc.work);
|
||||
if (_msg) {
|
||||
ESI = math.min(status_w/6, strlen(_msg));
|
||||
@@ -920,7 +920,7 @@ dword GetAbsoluteActiveURL()
|
||||
void CheckContentType()
|
||||
{
|
||||
char content_type[64];
|
||||
if (http.header_field("content-type", #content_type, sizeof(content_type))) // application || image
|
||||
if (http.header_field("content-type", #content_type, sizeof(content_type)-1)) // application || image
|
||||
|
||||
if (content_type[0] == 'i') {
|
||||
EventDownloadAndOpenImage(http.cur_url);
|
||||
@@ -968,12 +968,14 @@ dword GetImg(bool _new)
|
||||
for (i = 0; i < WB1.img_url.count; i++)
|
||||
{
|
||||
cur_img_url = WB1.img_url.get(i);
|
||||
if (debug_mode)
|
||||
{debug("get img: ");debugln(cur_img_url);}
|
||||
if (cache.has(cur_img_url)==false) {
|
||||
prbar.max = WB1.img_url.count;
|
||||
prbar.value = i;
|
||||
if (GetUrl(cur_img_url)) {DrawStatusBar(cur_img_url); DrawProgress(); return;}
|
||||
if (GetUrl(cur_img_url)) {
|
||||
DrawStatusBar(cur_img_url);
|
||||
DrawProgress();
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (_new) return;
|
||||
|
@@ -112,4 +112,4 @@ char editbox_icons[] = FROM "res/editbox_icons.raw";
|
||||
|
||||
#define DEFAULT_URL URL_SERVICE_HOMEPAGE
|
||||
|
||||
char version[]="WebView 3.82";
|
||||
char version[]="WebView 3.85";
|
@@ -2,38 +2,38 @@
|
||||
<title>TEST</title>
|
||||
<style>a {display:block;font-size:130%;margin:5px 40px 5px 0;}</style>
|
||||
<body>
|
||||
<pre><a href=//wiby.org>wiby.org</a>
|
||||
<a href=//www.xlr8yourmac.com/OSX/os_x_network_cards.html>OSX network cards</a>
|
||||
<a href=//macintoshgarden.org/>Macintosh Garden</a>
|
||||
|
||||
<table><tr><td>Simplest:
|
||||
<a href=//nostalgy.net.ru/>nostalgy.net.ru</a>
|
||||
<pre><h2>HTTP</h2>
|
||||
<a href=//th99.infania.net>Total Hardware 1999</a>
|
||||
<a href=//wiby.org>wiby.org</a>
|
||||
<a href=//menuetos.net>menuetos.net</a>
|
||||
<a href=//macintosh.garden/>Macintosh Garden</a>
|
||||
<a href=//pci-ids.ucw.cz>pci.ids</a>
|
||||
<a href=//toastytech.com/guis/index.html>GUI Gallery</a>
|
||||
<a href=//www.weitek.com/textual/support/driver.html>weitek</a>
|
||||
<a href=//www.abandonwarering.com/?Page=Listing>abandonware</a>
|
||||
<a href=//neonfloppy.sytes.net/articles/win3-usb/>neonfloppy</a>
|
||||
<a href=//www.win31.de/eindex.htm>win31.de</a>
|
||||
|
||||
<h3>VPN-only</h3>
|
||||
<a href=//dgmag.in>dgmag.in</a>
|
||||
<a href=//web.archive.org/web/https://bash.im>bash.im</a>
|
||||
<a href=//web.archive.org/web/https://opennet.ru>opennet</a>
|
||||
<a href=//linux.org.ru>LOR</a>
|
||||
<a href=//web.archive.org/web/https://samlib.ru/b>samlib.ru/b</a>
|
||||
<a href=//web.archive.org/web/https://mirrors.pdp-11.ru>mirrors.pdp-11.ru</a>
|
||||
<a href=//web.archive.org/web/http://gona.mactar.hu/ATI_Mac/>ATI drivers for Mac</a>
|
||||
<td>Simple:
|
||||
<a href=//web.archive.org/web/http://lionovsky.us>lionovsky.us</a>
|
||||
<a href=//fdd5-25.pdp-11.ru>fdd5-25</a>
|
||||
<a href=//old-dos.ru>old-dos.ru</a>
|
||||
<a href=//artcon.ru>artcon.ru</a>
|
||||
<a href=//nubo.ru>nubo.ru</a>
|
||||
<a href=//mirrors.pdp-11.ru>mirrors.pdp-11.ru</a>
|
||||
<a href=//nostalgy.net.ru/>nostalgy.net.ru</a>
|
||||
|
||||
<h2>HTTPS :(</h2>
|
||||
<a href=//os-menuet.narod.ru>os-menuet.narod.ru</a>
|
||||
<a href=//mestack.narod.ru/index.html>mestack.narod.ru</a>
|
||||
<a href=//coolthemes.narod.ru/indexold.html>coolthemes.narod.ru</a>
|
||||
<a href=//vetusware.com>vetusware.com</a>
|
||||
<a href=//th99.infania.net>Total Hardware 1999</a>
|
||||
<a href=//toastytech.com/guis/index.html>GUI Gallery</a>
|
||||
<a href=//menuetos.net>menuetos.net</a>
|
||||
<tr><td>
|
||||
Moderate:
|
||||
<a href=//fdd5-25.pdp-11.ru>fdd5-25</a>
|
||||
<a href=//lionovsky.us>lionovsky.us</a>
|
||||
<a href=//acmp.ru/index.asp?main=tasks>acmp.ru</a>
|
||||
<a href=//old-dos.ru>old-dos.ru</a>
|
||||
<a href=//www.weitek.com/textual/support/driver.html>weitek</a>
|
||||
<a href=//www.abandonwarering.com/?Page=Listing>abandonware</a>
|
||||
<td>Complex:
|
||||
<a href=//web.archive.org/web/https://artcon.ru>artcon.ru</a>
|
||||
<a href=//nubo.ru>nubo.ru</a>
|
||||
<a href=//xn--80abh7bk0c.xn--p1ai>bashorg</a>
|
||||
<a href=//opennet.ru>opennet</a>
|
||||
<a href=//linux.org.ru>LOR</a>
|
||||
<a href=//www.xlr8yourmac.com/OSX/os_x_network_cards.html>OSX network cards</a>
|
||||
<a href=//samlib.ru/b>samlib.ru/b</a>
|
||||
<a href=//vetusware.com>vetusware.com</a>
|
||||
<a href=//electromyne.de>electromyne.de</a>
|
||||
<a href=//web.archive.org/web/20190403215447//www.thg.ru/>thg</a>
|
@@ -11,9 +11,9 @@ TODO:
|
||||
http://board.kolibrios.org/viewtopic.php?f=23&t=4521&p=77334#p77334
|
||||
*/
|
||||
|
||||
#define ABOUT_TITLE "EOLITE 5.28"
|
||||
#define TITLE_EOLITE "Eolite File Manager 5.28"
|
||||
#define TITLE_KFM "Kolibri File Manager 2.28";
|
||||
#define ABOUT_TITLE "EOLITE 5.29"
|
||||
#define TITLE_EOLITE "Eolite File Manager 5.29"
|
||||
#define TITLE_KFM "Kolibri File Manager 2.29";
|
||||
|
||||
#define MEMSIZE 1024 * 250
|
||||
#include "../lib/clipboard.h"
|
||||
@@ -195,6 +195,8 @@ void main()
|
||||
|
||||
handle_param();
|
||||
|
||||
kfont.init(DEFAULT_FONT);
|
||||
|
||||
SystemDiscs.Get();
|
||||
OpenDir(ONLY_OPEN);
|
||||
llist_copy(#files_inactive, #files);
|
||||
|
@@ -175,8 +175,10 @@ void properties_dialog()
|
||||
break;
|
||||
|
||||
case evMouse:
|
||||
edit_box_mouse stdcall (#file_name_ed);
|
||||
edit_box_mouse stdcall (#path_to_file_ed);
|
||||
if (!apply_question_active) {
|
||||
edit_box_mouse stdcall (#file_name_ed);
|
||||
edit_box_mouse stdcall (#path_to_file_ed);
|
||||
}
|
||||
break;
|
||||
|
||||
case evKey:
|
||||
|
@@ -7,7 +7,7 @@ edit_box path_start_ed = {290,50,57,0xffffff,0x94AECE,0xffffff,0xffffff,0x100000
|
||||
#path_start,0, 100000000000010b,0,0};
|
||||
|
||||
more_less_box font_size = { NULL, 9, 22, FONT_SIZE_LABEL };
|
||||
more_less_box line_height = { NULL, 16, 64, LIST_LINE_HEIGHT };
|
||||
more_less_box line_height = { NULL, 18, 64, LIST_LINE_HEIGHT };
|
||||
checkbox show_dev_name = { SHOW_DEVICE_CLASS };
|
||||
checkbox big_icons = { BIG_ICONS };
|
||||
checkbox colored_lines = { COLORED_LINES };
|
||||
@@ -134,7 +134,6 @@ void LoadIniSettings()
|
||||
Form.height = ini.GetInt("WinH", efm*100+517);
|
||||
ini.GetString("DefaultPath", #path_start, 4096, "/sys");
|
||||
path_start_ed.size = path_start_ed.pos = strlen(#path_start);
|
||||
kfont.init(DEFAULT_FONT);
|
||||
ini_get_str stdcall ("/sys/SETTINGS/SYSTEM.INI", "system", "font smoothing",#temp,4096,"on");
|
||||
if(streq(#temp,"off")) kfont.smooth = false; else kfont.smooth = true;
|
||||
}
|
||||
|
@@ -26,15 +26,9 @@ struct collection_int
|
||||
|
||||
:void collection_int::add(dword _in) {
|
||||
unsigned i;
|
||||
if (!buf) {
|
||||
//if (buf_size) notify("'buf_size on empty buf' -A");
|
||||
buf_size = 4096 * 5;
|
||||
buf = malloc(4096 * 5);
|
||||
//if (!buf) notify("'malloc error' -E");
|
||||
} else if (count + 1 * DWSIZE4 >= buf_size) {
|
||||
if (!buf) || (count + 1 * DWSIZE4 >= buf_size) {
|
||||
buf_size += 4096 * 5;
|
||||
buf = realloc(buf, buf_size);
|
||||
//if (!buf) notify("'realloc error' -E");
|
||||
}
|
||||
i = count * DWSIZE4 + buf;
|
||||
ESDWORD[i] = _in;
|
||||
@@ -77,8 +71,8 @@ struct collection_int
|
||||
|
||||
:void collection_int::drop() {
|
||||
count = 0;
|
||||
if (buf) buf = free(buf);
|
||||
buf_size = 0;
|
||||
//if (buf) buf = free(buf);
|
||||
//buf_size = 0;
|
||||
}
|
||||
|
||||
/*========================================================
|
||||
@@ -97,31 +91,30 @@ struct collection
|
||||
dword get(); //get_name_by_pos
|
||||
dword get_pos_by_name();
|
||||
void drop();
|
||||
void increase_data_size();
|
||||
dword get_last();
|
||||
bool pop();
|
||||
};
|
||||
|
||||
:void collection::increase_data_size() {
|
||||
if (realloc_size<4096) realloc_size = 4096;
|
||||
if (!data_size) {
|
||||
data_size = realloc_size;
|
||||
data_start = malloc(data_size);
|
||||
} else {
|
||||
data_size = data_size + realloc_size;
|
||||
data_start = realloc(data_start, data_size);
|
||||
}
|
||||
}
|
||||
|
||||
:dword collection::add(dword in) {
|
||||
dword len = strlen(in);
|
||||
while (offset.get(count) + len + 4 > data_size) {
|
||||
increase_data_size();
|
||||
unsigned cur_buf_size;
|
||||
|
||||
if (!count) {
|
||||
cur_buf_size = 0;
|
||||
} else {
|
||||
cur_buf_size = offset.get(count);
|
||||
}
|
||||
strncpy(data_start+offset.get(count), in, len);
|
||||
|
||||
if (realloc_size<4096) realloc_size = 4096;
|
||||
while (cur_buf_size + len + 4 > data_size) {
|
||||
data_size += realloc_size;
|
||||
data_start = realloc(data_start, data_size);
|
||||
}
|
||||
|
||||
strncpy(data_start+cur_buf_size, in, len);
|
||||
count++;
|
||||
offset.set(count, offset.get(count-1) + len + 1);
|
||||
return data_start+offset.get(count-1);
|
||||
offset.set(count, cur_buf_size + len + 1);
|
||||
return data_start + cur_buf_size;
|
||||
}
|
||||
|
||||
:dword collection::get(dword pos) {
|
||||
|
@@ -17,17 +17,25 @@ struct CANVAS {
|
||||
void Show();
|
||||
void Fill();
|
||||
void DrawBar();
|
||||
void DrawImage();
|
||||
void WriteText();
|
||||
void PutPixel();
|
||||
void AlignCenter();
|
||||
void AlignRight();
|
||||
void IncreaseBufSize();
|
||||
bool BufIsInvalid();
|
||||
};
|
||||
|
||||
char draw_buf_not_enaught_ram[] =
|
||||
"'CANVAS requested %i MB more memory than the system has.
|
||||
Application could be unstable.' -E";
|
||||
|
||||
bool CANVAS::BufIsInvalid()
|
||||
{
|
||||
if (!buf_data) || (!bufw) return true;
|
||||
return false;
|
||||
}
|
||||
|
||||
bool CANVAS::Init(dword i_bufx, i_bufy, i_bufw, i_bufh)
|
||||
{
|
||||
bufx = i_bufx;
|
||||
@@ -45,6 +53,7 @@ bool CANVAS::Init(dword i_bufx, i_bufy, i_bufw, i_bufh)
|
||||
void CANVAS::Fill(dword start_pointer, i_fill_color)
|
||||
{
|
||||
dword max_i = bufw * bufh * 4 - start_pointer/4;
|
||||
if (BufIsInvalid()) return;
|
||||
fill_color = i_fill_color | 0xFF000000; //set background color non-transparent
|
||||
@MEMSETD(buf_data+start_pointer+8, max_i, fill_color);
|
||||
}
|
||||
@@ -52,6 +61,7 @@ void CANVAS::Fill(dword start_pointer, i_fill_color)
|
||||
void CANVAS::DrawBar(dword x, y, w, h, color)
|
||||
{
|
||||
dword i, j;
|
||||
if (BufIsInvalid()) return;
|
||||
if (y + h >= bufh) IncreaseBufSize();
|
||||
for (j=0; j<h; j++) {
|
||||
for (i = y+j*bufw+x<<2+8+buf_data; i<y+j*bufw+x+w<<2+8+buf_data; i+=4) {
|
||||
@@ -60,12 +70,30 @@ void CANVAS::DrawBar(dword x, y, w, h, color)
|
||||
}
|
||||
}
|
||||
|
||||
void CANVAS::DrawImage(dword x, y, w, h, img)
|
||||
{
|
||||
dword i, j, p=0;
|
||||
dword ystart;
|
||||
if (BufIsInvalid()) return;
|
||||
if (y < 0) y = 0;
|
||||
if (x < 0) x = 0;
|
||||
while (y + h >= bufh) IncreaseBufSize(); //WHY NOT WORKING?
|
||||
for (j=0; j<h; j++) {
|
||||
ystart = y + j * bufw + x;
|
||||
for (i = ystart<<2+8+buf_data; i<ystart+w<<2+8+buf_data; i+=4) {
|
||||
ESDWORD[i] = ESDWORD[img+p];
|
||||
p+=4;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void CANVAS::WriteText(dword x, y, byte fontType, dword color, str_offset, strlen)
|
||||
{
|
||||
#define BUGFIX_32000 32000
|
||||
dword ydiv=0;
|
||||
dword reserve_data_1, reserve_data_2;
|
||||
dword new_buf_offset;
|
||||
if (BufIsInvalid()) return;
|
||||
if (y + 30 >= bufh) IncreaseBufSize();
|
||||
if (y < BUGFIX_32000) {
|
||||
ESI = strlen;
|
||||
@@ -92,6 +120,7 @@ void CANVAS::WriteText(dword x, y, byte fontType, dword color, str_offset, strle
|
||||
void CANVAS::PutPixel(dword x, y, color)
|
||||
{
|
||||
dword pos = y*bufw+x*4+8+buf_data;
|
||||
if (BufIsInvalid()) return;
|
||||
ESDWORD[pos] = color;
|
||||
}
|
||||
|
||||
@@ -99,6 +128,7 @@ void CANVAS::AlignRight(dword x,y,w,h, content_width)
|
||||
{
|
||||
dword i, j, l;
|
||||
dword content_left = w - content_width / 2;
|
||||
if (BufIsInvalid()) return;
|
||||
for (j=0; j<h; j++)
|
||||
{
|
||||
for (i=j*w+w-x*4, l=j*w+content_width+x*4; (i>=j*w+content_left*4) && (l>=j*w*4); i-=4, l-=4)
|
||||
@@ -112,6 +142,7 @@ void CANVAS::AlignCenter(dword x,y,w,h, content_width)
|
||||
{
|
||||
dword i, j, l;
|
||||
dword content_left = w - content_width / 2;
|
||||
if (BufIsInvalid()) return;
|
||||
for (j=0; j<h; j++)
|
||||
{
|
||||
for (i=j*w+content_width+content_left*4, l=j*w+content_width+x*4; (i>=j*w+content_left*4) && (l>=j*w*4); i-=4, l-=4)
|
||||
@@ -123,6 +154,7 @@ void CANVAS::AlignCenter(dword x,y,w,h, content_width)
|
||||
|
||||
void CANVAS::Show(dword _y_offset, _h)
|
||||
{
|
||||
if (BufIsInvalid()) return;
|
||||
PutPaletteImage(_y_offset * bufw * 4 + buf_data+8, bufw, _h, bufx, bufy, 32, 0);
|
||||
}
|
||||
|
||||
@@ -133,6 +165,8 @@ void CANVAS::IncreaseBufSize()
|
||||
dword free_ram_size;
|
||||
char error_str[256];
|
||||
|
||||
if (!bufw) return;
|
||||
|
||||
if (!buf_data) {
|
||||
alloc_size = bufh * bufw * 4 + 8;
|
||||
buf_data = malloc(alloc_size);
|
||||
|
@@ -254,10 +254,7 @@ init_palette:
|
||||
|
||||
;init buffer
|
||||
mcall SF_SYS_MISC,SSF_HEAP_INIT
|
||||
mov ecx,[Screen_W]
|
||||
imul ecx,[Screen_H]
|
||||
mcall SF_SYS_MISC,SSF_MEM_ALLOC
|
||||
mov [buffer],eax
|
||||
call OnResize
|
||||
|
||||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||
; Main Functions
|
||||
@@ -281,6 +278,7 @@ OnResize:
|
||||
imul ecx,[Screen_H]
|
||||
;ecx = SCREEN_W*SCREEN_H
|
||||
mcall SF_SYS_MISC,SSF_MEM_REALLOC,,[buffer]
|
||||
mov [buffer],eax
|
||||
ret
|
||||
|
||||
align 4
|
||||
|
@@ -20,7 +20,7 @@ include '../../KOSfuncs.inc'
|
||||
|
||||
title db 'Tube - FPU',0
|
||||
|
||||
SCREEN_W dd 640-10 ;10 px for borders
|
||||
SCREEN_W dd 600-10 ;10 px for borders
|
||||
SCREEN_H dd 400-10
|
||||
|
||||
align 4
|
||||
@@ -28,7 +28,8 @@ START:
|
||||
mcall SF_SYS_MISC,SSF_HEAP_INIT
|
||||
call OnResize
|
||||
call draw_window
|
||||
call init_tube
|
||||
fninit
|
||||
fldz
|
||||
push ebx
|
||||
|
||||
still:
|
||||
@@ -56,8 +57,6 @@ OnResize:
|
||||
;ecx = SCREEN_W*SCREEN_H
|
||||
mcall SF_SYS_MISC,SSF_MEM_REALLOC,,[PIXBUF]
|
||||
mov [PIXBUF],eax
|
||||
mcall SF_SYS_MISC,SSF_MEM_REALLOC,,[buf1]
|
||||
mov [buf1],eax
|
||||
lea ecx,[ecx+2*ecx]
|
||||
mcall SF_SYS_MISC,SSF_MEM_REALLOC,,[buf2]
|
||||
mov [buf2],eax
|
||||
@@ -159,14 +158,14 @@ STORE_1:
|
||||
|
||||
call display_image
|
||||
|
||||
pop esi
|
||||
pop esi ;esi=PIXBUF
|
||||
mov ecx,[SCREEN_W]
|
||||
imul ecx,[SCREEN_H]
|
||||
|
||||
align 4
|
||||
BLUR:
|
||||
inc esi
|
||||
sar byte [esi],2
|
||||
inc esi
|
||||
loop BLUR
|
||||
ret
|
||||
|
||||
@@ -185,13 +184,15 @@ newp:
|
||||
movzx edx,byte [esi]
|
||||
shl edx,4
|
||||
|
||||
mov [edi],edx
|
||||
mov word [edi],dx ;blue,green
|
||||
;shr edx,16
|
||||
;mov [edi+2],dl ;red - not used
|
||||
|
||||
add edi,3
|
||||
inc esi
|
||||
|
||||
cmp esi,eax
|
||||
jbe newp
|
||||
jb newp
|
||||
|
||||
xor edx,edx
|
||||
mov ecx,[SCREEN_W]
|
||||
@@ -253,57 +254,10 @@ align 4
|
||||
TEXUV:
|
||||
rd 1
|
||||
|
||||
align 4
|
||||
init_tube:
|
||||
mov ecx,256
|
||||
mov edi,[buf1]
|
||||
|
||||
PAL1:
|
||||
mov edx,3C8h
|
||||
mov eax,ecx
|
||||
inc edx
|
||||
sar al,1
|
||||
js PAL2
|
||||
mul al
|
||||
shr ax,6
|
||||
|
||||
PAL2:
|
||||
mov al,0
|
||||
jns PAL3
|
||||
sub al,cl
|
||||
shr al,1
|
||||
shr al,1
|
||||
|
||||
PAL3:
|
||||
mov ebx,ecx
|
||||
mov [ebx+edi],bh
|
||||
loop PAL1
|
||||
mov ecx,256
|
||||
|
||||
TEX:
|
||||
mov bx,cx
|
||||
add ax,cx
|
||||
rol ax,cl
|
||||
mov dh,al
|
||||
sar dh,5
|
||||
adc dl,dh
|
||||
adc dl,[ebx+255+edi]
|
||||
shr dl,1
|
||||
mov [ebx+edi],dl
|
||||
not bh
|
||||
mov [ebx+edi],dl
|
||||
loop TEX
|
||||
|
||||
fninit
|
||||
fldz
|
||||
|
||||
ret
|
||||
|
||||
align 4
|
||||
image_end:
|
||||
|
||||
PIXBUF rd 1
|
||||
buf1 rd 1
|
||||
buf2 rd 1
|
||||
procinfo process_information
|
||||
|
||||
|
@@ -601,6 +601,8 @@ edit_box_mouse:
|
||||
jnz edit_box_mouse.mouse_left_button
|
||||
and word ed_flags,ed_mouse_on_off
|
||||
mov ebx,ed_mouse_variable
|
||||
or ebx,ebx
|
||||
jz edit_box_exit
|
||||
push 0
|
||||
pop dword [ebx]
|
||||
jmp edit_box_exit
|
||||
@@ -610,13 +612,14 @@ edit_box_mouse:
|
||||
;--- <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><E0AEA2> <20><> 䮪<><E4AEAA><EFBFBD><EFBFBD><E0AEA2> <20> <20><>㣨<EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><> <20><><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
;----------------------------------------------------------
|
||||
mov eax,ed_mouse_variable
|
||||
test eax,eax
|
||||
jz @f ;<3B> ed_mouse_variable=0
|
||||
push dword [eax]
|
||||
pop eax
|
||||
test eax,eax
|
||||
jz @f
|
||||
jz @f ;<3B> [ed_mouse_variable]=0
|
||||
cmp eax,edi
|
||||
je @f
|
||||
jmp edit_box_mouse._blur
|
||||
jne edit_box_mouse._blur
|
||||
;----------------------------------------------------------
|
||||
;--- <20><><EFBFBD><EFBFBD>砥<EFBFBD> <20><><EFBFBD>न<EFBFBD><E0A4A8><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20>⭮<EFBFBD><E2ADAE>⥫쭮 0 <20>.<2E> <20>ᥩ <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><>࠭<EFBFBD>
|
||||
;----------------------------------------------------------
|
||||
@@ -672,8 +675,11 @@ edit_box_mouse._mshift:
|
||||
or word ed_flags,ed_mouse_on
|
||||
mov ed_pos,eax
|
||||
mov ebx,ed_mouse_variable
|
||||
or ebx,ebx
|
||||
jz edit_box_mouse.mv_end
|
||||
push edi
|
||||
pop dword [ebx]
|
||||
edit_box_mouse.mv_end:
|
||||
bts word ed_flags,1
|
||||
call edit_box_draw.bg
|
||||
jmp edit_box_mouse.m_sh
|
||||
|
@@ -1675,6 +1675,14 @@ proc generate_window_header
|
||||
mov eax, [ebx+Image.Height]
|
||||
call bin2dec
|
||||
|
||||
mov eax, [ebx+Image.Type]
|
||||
dec eax
|
||||
shl eax, 2
|
||||
add eax, BppTypeNames
|
||||
mov eax, [eax]
|
||||
mov dword[edi], eax
|
||||
add edi, 4
|
||||
|
||||
mov byte[edi], ')'
|
||||
inc edi
|
||||
|
||||
@@ -2544,6 +2552,18 @@ db 'XBM',0
|
||||
.end:
|
||||
db 0
|
||||
|
||||
BppTypeNames:
|
||||
db '@08b'
|
||||
db '@24b'
|
||||
db '@32b'
|
||||
db '@15b'
|
||||
db '@16b'
|
||||
db '@01b'
|
||||
db '@8gr'
|
||||
db '@02b'
|
||||
db '@04b'
|
||||
db '@08a'
|
||||
|
||||
draw_window_fake:
|
||||
ret
|
||||
;------------------------------------------------------------------------------
|
||||
|
@@ -1,12 +1,12 @@
|
||||
draw_palitra:
|
||||
; <EFBFBD>㭪<EFBFBD><EFBFBD><EFBFBD> 13 - <EFBFBD><EFBFBD><EFBFBD><EFBFBD>ᮢ<EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD>אַ㣮<EFBFBD>쭨<EFBFBD>
|
||||
;mcall SF_DRAW_RECT, 110 shl 16+148, 9 shl 16+148, [sc.work]
|
||||
;mcall SF_DRAW_RECT, PALITRA_XW, PALITRA_YW, [sc.work]
|
||||
|
||||
cmp [renmode],2
|
||||
cmp [renmode],MODE_PIPET
|
||||
je cyrcle_draw
|
||||
;cmp [renmode],1
|
||||
;je picker_draw
|
||||
cmp [renmode],0
|
||||
cmp [renmode],MODE_PALITRA
|
||||
je sheme_draw
|
||||
ret
|
||||
|
||||
@@ -39,6 +39,15 @@ draw_palitra:
|
||||
;mov ebx,109*65536+150
|
||||
;mov ecx, 10*65536+150
|
||||
;mcall
|
||||
|
||||
PIPET_CELLW = 13
|
||||
PIPET_AREA_W = PIPET_CELLW*PIPET_CELL_COUNT_X
|
||||
PIPET_AREA_H = PIPET_CELLW*PIPET_CELL_COUNT_Y
|
||||
PIPET_CELL_COUNT_X = 15
|
||||
PIPET_CELL_COUNT_Y = 13
|
||||
PIPET_SELECTED_X = PIPET_AREA_W/2+PALITRA_X
|
||||
PIPET_SELECTED_Y = PIPET_AREA_H/2+DRAWY+2
|
||||
|
||||
call mouse_local ; <EFBFBD><EFBFBD><EFBFBD><EFBFBD>砥<EFBFBD> <EFBFBD><EFBFBD><EFBFBD>न<EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD>⭮<EFBFBD><EFBFBD>⥫쭮 <EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
mov ecx, [mouse_x] ; <EFBFBD><EFBFBD><EFBFBD><EFBFBD>ᨬ <EFBFBD> ॣ<EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
mov edx, [mouse_y] ; <EFBFBD><EFBFBD><EFBFBD><EFBFBD>ᨬ <EFBFBD> ॣ<EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
@@ -52,38 +61,39 @@ draw_palitra:
|
||||
call desktop_get
|
||||
call mouse_global
|
||||
|
||||
mov ebx,112*65536+11
|
||||
mov ebx,PALITRA_X*65536+PIPET_CELLW
|
||||
mov esi,0 ; counter=8
|
||||
circle_loop:
|
||||
mov ecx, 10*65536+11
|
||||
mov ecx, (DRAWY+1)*65536+PIPET_CELLW
|
||||
mov edi,0
|
||||
circle_loop2:
|
||||
call circle_pixel_read
|
||||
mcall SF_DRAW_RECT
|
||||
add ecx,11 shl 16
|
||||
add ecx,PIPET_CELLW shl 16
|
||||
inc edi
|
||||
cmp edi,13
|
||||
cmp edi,PIPET_CELL_COUNT_Y
|
||||
jne circle_loop2
|
||||
|
||||
add ebx,11 shl 16
|
||||
add ebx,PIPET_CELLW shl 16
|
||||
inc esi
|
||||
cmp esi,13
|
||||
cmp esi,PIPET_CELL_COUNT_X
|
||||
jne circle_loop
|
||||
|
||||
mcall SF_DRAW_RECT, 177*65536+13, 76*65536+13, 0
|
||||
mcall SF_DRAW_RECT, <PIPET_SELECTED_X-10, PIPET_CELLW+4>, <PIPET_SELECTED_Y-10, PIPET_CELLW+4>, 0xFF0000
|
||||
mov ecx, [mouse_x]
|
||||
mov edx, [mouse_y]
|
||||
inc ecx
|
||||
inc ecx
|
||||
inc edx
|
||||
mov ebx, edx
|
||||
imul ebx, [desctop_w]
|
||||
add ebx, ecx
|
||||
mcall SF_GET_PIXEL
|
||||
mov edx,eax
|
||||
mcall SF_DRAW_RECT, 178*65536+11, 77*65536+11
|
||||
mcall SF_DRAW_RECT, <PIPET_SELECTED_X-8, PIPET_CELLW>, <PIPET_SELECTED_Y-8, PIPET_CELLW>
|
||||
ret
|
||||
end_cyrcle_draw:
|
||||
mcall SF_DRAW_RECT, 111*65536+145, 9*65536+145, 0x666666
|
||||
mcall SF_DRAW_RECT, <PALITRA_X-1, PIPET_AREA_W+2>, <DRAWY, PIPET_AREA_H+2>, [sc.work_graph]
|
||||
ret
|
||||
|
||||
circle_pixel_read:
|
||||
@@ -124,20 +134,20 @@ draw_palitra:
|
||||
sheme_draw:
|
||||
mov eax,SF_DRAW_RECT ; <EFBFBD>㭪<EFBFBD><EFBFBD><EFBFBD> 13 - <EFBFBD><EFBFBD><EFBFBD><EFBFBD>ᮢ<EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD>אַ㣮<EFBFBD>쭨<EFBFBD>
|
||||
mov edx,0x222222 ; 梥<EFBFBD>
|
||||
mov ecx, palitra_yw ; <EFBFBD><EFBFBD>砫<EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD><EFBFBD>न<EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD> y [<EFBFBD>-<EFBFBD><EFBFBD> y]*65536 + [ࠧ<EFBFBD><EFBFBD><EFBFBD>]
|
||||
mov ecx, PALITRA_YW ; <EFBFBD><EFBFBD>砫<EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD><EFBFBD>न<EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD> y [<EFBFBD>-<EFBFBD><EFBFBD> y]*65536 + [ࠧ<EFBFBD><EFBFBD><EFBFBD>]
|
||||
mov esi,2 ; <EFBFBD><EFBFBD><EFBFBD><EFBFBD>稪 <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
re_draw:
|
||||
mov ebx,palitra_xw ; <EFBFBD><EFBFBD>砫<EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD><EFBFBD>न<EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD> x [<EFBFBD>-<EFBFBD><EFBFBD> x]*65536 + [ࠧ<EFBFBD><EFBFBD><EFBFBD>]
|
||||
mov ebx,PALITRA_XW ; <EFBFBD><EFBFBD>砫<EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD><EFBFBD>न<EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD> x [<EFBFBD>-<EFBFBD><EFBFBD> x]*65536 + [ࠧ<EFBFBD><EFBFBD><EFBFBD>]
|
||||
mov edi,2 ; <EFBFBD><EFBFBD><EFBFBD><EFBFBD>稪 <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⢠ <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
for_fon_loop:
|
||||
int 0x40 ; <EFBFBD><EFBFBD><EFBFBD><EFBFBD>뢠<EFBFBD><EFBFBD><EFBFBD>
|
||||
add ebx,(palitra_w+2) shl 16 ; <EFBFBD><EFBFBD><EFBFBD>頥<EFBFBD> <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD> <EFBFBD>
|
||||
add ebx,(PALITRA_W+2) shl 16 ; <EFBFBD><EFBFBD><EFBFBD>頥<EFBFBD> <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD> <EFBFBD>
|
||||
dec edi ; <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>蠥<EFBFBD> <EFBFBD><EFBFBD><EFBFBD><EFBFBD>稪 <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
cmp edi,0 ; <EFBFBD>ࠢ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD> <EFBFBD>㫥<EFBFBD>
|
||||
jnz for_fon_loop ; <EFBFBD> <EFBFBD><EFBFBD> <EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD> <EFBFBD> <EFBFBD><EFBFBD>砫<EFBFBD> 横<EFBFBD><EFBFBD>
|
||||
dec esi ; <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>蠥<EFBFBD> <EFBFBD><EFBFBD><EFBFBD>
|
||||
cmp esi,0 ; <EFBFBD>ࠢ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD> <EFBFBD>㫥<EFBFBD>
|
||||
mov ecx,(palitra_w+DRAWY+3) shl 16+palitra_w ; <EFBFBD><EFBFBD>砫<EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD><EFBFBD>न<EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD> y [<EFBFBD>-<EFBFBD><EFBFBD> y]*65536 + [ࠧ<EFBFBD><EFBFBD><EFBFBD>]
|
||||
mov ecx,(PALITRA_W+DRAWY+3) shl 16+PALITRA_W ; <EFBFBD><EFBFBD>砫<EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD><EFBFBD>न<EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD> y [<EFBFBD>-<EFBFBD><EFBFBD> y]*65536 + [ࠧ<EFBFBD><EFBFBD><EFBFBD>]
|
||||
jnz re_draw ; <EFBFBD> <EFBFBD><EFBFBD> <EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD> <EFBFBD> <EFBFBD><EFBFBD>砫<EFBFBD> 横<EFBFBD><EFBFBD>
|
||||
|
||||
;.................................................................................................
|
||||
@@ -146,12 +156,12 @@ draw_palitra:
|
||||
mov eax,SF_DRAW_RECT ; <EFBFBD>㭪<EFBFBD><EFBFBD><EFBFBD> 13 - <EFBFBD><EFBFBD><EFBFBD><EFBFBD>ᮢ<EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD>אַ㣮<EFBFBD>쭨<EFBFBD>
|
||||
mov edx,0x0FFFFFFF ; 梥<EFBFBD>
|
||||
mov esi,4 ; <EFBFBD><EFBFBD><EFBFBD><EFBFBD>稪 <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⢠ <EFBFBD><EFBFBD><EFBFBD><EFBFBD>楢 (#4,8)
|
||||
mov ebx,(palitra_x-CELLW-3) shl 16+CELLW ; <EFBFBD><EFBFBD>砫<EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD><EFBFBD>न<EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD> x [<EFBFBD>-<EFBFBD><EFBFBD> x]*65536 + [ࠧ<EFBFBD><EFBFBD><EFBFBD>]
|
||||
mov ebx,(PALITRA_X-CELLW-3) shl 16+CELLW ; <EFBFBD><EFBFBD>砫<EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD><EFBFBD>न<EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD> x [<EFBFBD>-<EFBFBD><EFBFBD> x]*65536 + [ࠧ<EFBFBD><EFBFBD><EFBFBD>]
|
||||
for_abz:
|
||||
;;push esi ; <EFBFBD><EFBFBD><EFBFBD>࠭塞 <EFBFBD><EFBFBD><EFBFBD>祭<EFBFBD><EFBFBD> <EFBFBD><EFBFBD><EFBFBD><EFBFBD>稪<EFBFBD> <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD> <EFBFBD>⥪
|
||||
cmp esi,2
|
||||
jne x2_line
|
||||
mov ebx,(palitra_x-CELLW-3) shl 16+CELLW
|
||||
mov ebx,(PALITRA_X-CELLW-3) shl 16+CELLW
|
||||
x2_line:
|
||||
add ebx,3 shl 16 ; <EFBFBD><EFBFBD><EFBFBD>頥<EFBFBD> <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD> x
|
||||
mov edi,8 ; <EFBFBD><EFBFBD><EFBFBD><EFBFBD>稪 <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⢠ <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD> <EFBFBD><EFBFBD>ப<EFBFBD>
|
||||
@@ -161,7 +171,7 @@ draw_palitra:
|
||||
mov ecx, (1-CELLW/3) shl 16+CELLW ; <EFBFBD><EFBFBD>砫<EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD><EFBFBD>न<EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD> y [<EFBFBD>-<EFBFBD><EFBFBD> y]*65536 + [ࠧ<EFBFBD><EFBFBD><EFBFBD>]
|
||||
cmp esi,2
|
||||
jg y2_line ; <EFBFBD> <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> 4 <EFBFBD><EFBFBD> <EFBFBD><EFBFBD><EFBFBD><EFBFBD>ਬ
|
||||
mov ecx,(palitra_w+4-(CELLW/3)) shl 16+CELLW
|
||||
mov ecx,(PALITRA_W+4-(CELLW/3)) shl 16+CELLW
|
||||
y2_line:
|
||||
add ebx,(CELLW+1) shl 16 ; <EFBFBD><EFBFBD><EFBFBD>頥<EFBFBD> <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD> x
|
||||
for_loop:
|
||||
|
@@ -64,44 +64,46 @@
|
||||
;****************************************************************************************************|
|
||||
; <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><> |
|
||||
;----------------------------------------------------------------------------------------------------/
|
||||
use32
|
||||
org 0
|
||||
db 'MENUET01'
|
||||
dd 1,START,I_END,I_MEM,stacktop,params,sys_path
|
||||
use32
|
||||
org 0
|
||||
db 'MENUET01'
|
||||
dd 1,START,I_END,I_MEM,stacktop,params,sys_path
|
||||
|
||||
include '../../../macros.inc'
|
||||
include '../../../proc32.inc'
|
||||
include '../../../KOSfuncs.inc'
|
||||
include '../../../dll.inc'
|
||||
include '../../../macros.inc'
|
||||
include '../../../proc32.inc'
|
||||
include '../../../KOSfuncs.inc'
|
||||
include '../../../dll.inc'
|
||||
|
||||
include 'draw_sliders.inc'
|
||||
include 'draw_utils.inc'
|
||||
include 'draw_palitra.inc'
|
||||
include 'draw_sliders.inc'
|
||||
include 'draw_utils.inc'
|
||||
include 'draw_palitra.inc'
|
||||
|
||||
MODE_PALITRA = 0
|
||||
MODE_PIPET = 1
|
||||
|
||||
WIN_W = 374 ; <20><>ਭ<EFBFBD> <20><><EFBFBD><EFBFBD>
|
||||
WIN_H = 251 ; <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>
|
||||
WIN_X = 250 ; <20><><EFBFBD>न<EFBFBD><E0A4A8><EFBFBD><EFBFBD> <20> <20><><EFBFBD><EFBFBD>
|
||||
WIN_Y = 190 ; <20><><EFBFBD>न<EFBFBD><E0A4A8><EFBFBD><EFBFBD> <20> <20><><EFBFBD><EFBFBD>
|
||||
|
||||
WIN_W = 374 ; <20><>ਭ<EFBFBD> <20><><EFBFBD><EFBFBD>
|
||||
WIN_H = 251 ; <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>
|
||||
WIN_X = 250 ; <20><><EFBFBD>न<EFBFBD><E0A4A8><EFBFBD><EFBFBD> <20> <20><><EFBFBD><EFBFBD>
|
||||
WIN_Y = 190 ; <20><><EFBFBD>न<EFBFBD><E0A4A8><EFBFBD><EFBFBD> <20> <20><><EFBFBD><EFBFBD>
|
||||
Left_Border=4
|
||||
SliderPanel_W = 110
|
||||
DRAWY = 9
|
||||
|
||||
Left_Border=4
|
||||
SliderPanel_W = 110
|
||||
DRAWY = 9
|
||||
CELLW = 11; 11 ; not used yet, but has to be :)
|
||||
|
||||
CELLW = 11; 11 ; not used yet, but has to be :)
|
||||
ICONX = WIN_W - 39
|
||||
ICONS = 18 ; icon size
|
||||
SLIDEW = 25
|
||||
|
||||
ICONX = WIN_W - 39
|
||||
ICONS = 18 ; icon size
|
||||
SLIDEW = 25
|
||||
|
||||
palitra_x = Left_Border+SliderPanel_W+12
|
||||
palitra_w = CELLW*(8)+8+1
|
||||
palitra_xw = palitra_x shl 16 + palitra_w
|
||||
palitra_yw = DRAWY shl 16 + palitra_w
|
||||
PALITRA_X = Left_Border+SliderPanel_W+12
|
||||
PALITRA_W = CELLW*(8)+8+1
|
||||
PALITRA_XW = PALITRA_X shl 16 + PALITRA_W
|
||||
PALITRA_YW = DRAWY shl 16 + PALITRA_W
|
||||
|
||||
START:
|
||||
mcall SF_SYS_MISC,SSF_HEAP_INIT ; <20><><EFBFBD>樠<EFBFBD><E6A8A0><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>
|
||||
mcall SF_SYSTEM, SSF_WINDOW_BEHAVIOR, SSSF_SET_WB, -1, 1 ;always on top
|
||||
mcall SF_SYS_MISC,SSF_HEAP_INIT ; <20><><EFBFBD>樠<EFBFBD><E6A8A0><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>
|
||||
mcall SF_SYS_MISC, SSF_MEM_OPEN, i18_name
|
||||
mov [icons18], eax
|
||||
mcall SF_SYS_MISC, SSF_MEM_OPEN, i18bg_name
|
||||
@@ -138,7 +140,7 @@ key: ;
|
||||
;end_key
|
||||
|
||||
mouse:
|
||||
cmp [renmode],2
|
||||
cmp [renmode],MODE_PIPET
|
||||
jne left
|
||||
call cyrcle_draw
|
||||
jmp center
|
||||
@@ -171,7 +173,7 @@ button:
|
||||
cmp ah, 12 ; <20> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> NEXT
|
||||
jne next_bg ; <20><>室<EFBFBD><E5AEA4>
|
||||
inc [pnext] ; 㢥<><E3A2A5>稢<EFBFBD><E7A8A2><EFBFBD> <20><><EFBFBD> <20><><EFBFBD><EFBFBD>⨨ <20><><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
mov [renmode],0 ; <20><><EFBFBD><EFBFBD>砥<EFBFBD> 梥⮢<E6A2A5><E2AEA2> <20>奬<EFBFBD>
|
||||
mov [renmode],MODE_PALITRA ; <20><><EFBFBD><EFBFBD>砥<EFBFBD> 梥⮢<E6A2A5><E2AEA2> <20>奬<EFBFBD>
|
||||
mov eax,[pnext] ; <20><><EFBFBD><EFBFBD>ᨬ <20><><EFBFBD>祭<EFBFBD><E7A5AD> <20> <20><><EFBFBD>
|
||||
cmp al,6 ; <20>ࠢ<EFBFBD><E0A0A2><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20> <20><><EFBFBD><EFA2AB><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⢮<EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
jne next_redraw ; <20> <20><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD>ᨬ㬠 <20><> <20><> <20>맮<EFBFBD> <20><><EFBFBD><EFBFBD>ᮢ<EFBFBD><E1AEA2>
|
||||
@@ -181,19 +183,19 @@ button:
|
||||
call draw_palitra ; <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
jmp still ; <20>室<EFBFBD><E5AEA4> <20><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><>㣮<EFBFBD><E3A3AE> ᮡ<><E1AEA1><EFBFBD><EFBFBD>
|
||||
next_bg:
|
||||
cmp ah, 14 ; <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> BACKGROUND
|
||||
cmp ah, 14 ; <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> GRADIENT
|
||||
jne next_bg2 ; <20> <20><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><> <20><>室<EFBFBD><E5AEA4>
|
||||
call set_background ; <20><><EFBFBD><EFBFBD><EFBFBD> <20><>⠭<EFBFBD><E2A0AD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> 䮭
|
||||
jmp still ; <20> <20><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> ᮡ<><E1AEA1><EFBFBD><EFBFBD>
|
||||
next_bg2:
|
||||
cmp ah, 16 ; <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> BACKGROUND
|
||||
cmp ah, 16 ; <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> NOISY
|
||||
jne circle_bg ; <20> <20><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><> <20><>室<EFBFBD><E5AEA4>
|
||||
call set_background2 ; <20><><EFBFBD><EFBFBD><EFBFBD> <20><>⠭<EFBFBD><E2A0AD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> 䮭
|
||||
jmp still ; <20> <20><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> ᮡ<><E1AEA1><EFBFBD><EFBFBD>
|
||||
circle_bg:
|
||||
cmp ah, 15 ; <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><>㣮<EFBFBD><E3A3AE><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
jne next_end ; <20> <20><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><> <20><>室<EFBFBD><E5AEA4>
|
||||
mov [renmode],2 ; <20><><EFBFBD><EFBFBD>砥<EFBFBD> <20><><EFBFBD><EFBFBD>ᮢ<EFBFBD><E1AEA2> <20><>㣮<EFBFBD><E3A3AE><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
mov [renmode],MODE_PIPET ; <20><><EFBFBD><EFBFBD>砥<EFBFBD> <20><><EFBFBD><EFBFBD>ᮢ<EFBFBD><E1AEA2> <20><>㣮<EFBFBD><E3A3AE><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
call draw_palitra ; <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
jmp still ; <20> <20><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> ᮡ<><E1AEA1><EFBFBD><EFBFBD>
|
||||
next_end:
|
||||
@@ -252,15 +254,10 @@ button:
|
||||
; <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> |
|
||||
;----------------------------------------------------------------------------------------------------/
|
||||
draw_main:
|
||||
; <20>㭪<EFBFBD><E3ADAA><EFBFBD> 12: <20><><EFBFBD><EFBFBD>砥<EFBFBD>, <20><><EFBFBD> <20>㤥<EFBFBD> <20><>ᮢ<EFBFBD><E1AEA2><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>
|
||||
mcall SF_REDRAW,SSF_BEGIN_DRAW
|
||||
|
||||
; <20>㭪<EFBFBD><E3ADAA><EFBFBD> 48 - <20>⨫<EFBFBD> <20>⮡ࠦ<E2AEA1><E0A0A6><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>
|
||||
mcall SF_STYLE_SETTINGS,SSF_GET_COLORS,sc,sizeof.system_colors
|
||||
|
||||
; <20>㭪<EFBFBD><E3ADAA><EFBFBD> 48 - <20>⨫<EFBFBD> <20>⮡ࠦ<E2AEA1><E0A0A6><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>
|
||||
mcall SF_STYLE_SETTINGS,SSF_GET_SKIN_HEIGHT
|
||||
mov ecx,eax ; <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> ᪨<><E1AAA8>
|
||||
mov ecx,eax ; <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> ᪨<><E1AAA8>
|
||||
|
||||
mov edi,[runmode]
|
||||
cmp edi,2
|
||||
@@ -288,10 +285,10 @@ draw_main:
|
||||
call draw_palitra ; <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
call draw_result ; <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
|
||||
mcall SF_DEFINE_BUTTON, <palitra_x,palitra_w*2+1 > , <DRAWY,palitra_w*2+2>, 7+BT_HIDE ; palitra
|
||||
mcall SF_DEFINE_BUTTON, <PALITRA_X,PALITRA_W*2+1 > , <DRAWY,PALITRA_W*2+2>, 7+BT_HIDE+BT_NOFRAME ; palitra
|
||||
|
||||
inc edx
|
||||
mcall , <10,22>, <56,128> ; <20><><EFBFBD>㥬 <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD> <><E1ABA0><EFBFBD> red
|
||||
mcall , <10,22>, <54,136> ; <20><><EFBFBD>㥬 <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD> <><E1ABA0><EFBFBD> red
|
||||
add ebx,25*65536 ; <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>塞
|
||||
inc edx ; ID = 9
|
||||
int 0x40 ; <20><><EFBFBD>㥬 <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD> <><E1ABA0><EFBFBD> green
|
||||
@@ -303,103 +300,64 @@ draw_main:
|
||||
int 0x40 ; <20><><EFBFBD>㥬 <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD> <><E1ABA0><EFBFBD> alpha
|
||||
|
||||
; <20>㭪<EFBFBD><E3ADAA><EFBFBD> 8 - <20><>।<EFBFBD><E0A5A4><EFBFBD><EFBFBD><EFBFBD>/㤠<><E3A4A0><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> (<28><><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD>)
|
||||
mcall , <13,19>, <20,18>, 0x0D+BT_HIDE
|
||||
mcall , <10,22>, <16,20>, 13+BT_HIDE
|
||||
|
||||
call draw_bottom_panel
|
||||
call draw_left_panel
|
||||
call draw_right_panel
|
||||
|
||||
; <20>㭪<EFBFBD><E3ADAA><EFBFBD> 12: <20><><EFBFBD><EFBFBD>砥<EFBFBD>, <20><><EFBFBD> <20>㤥<EFBFBD> <20><>ᮢ<EFBFBD><E1AEA2><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>
|
||||
mcall SF_REDRAW,SSF_END_DRAW
|
||||
ret
|
||||
|
||||
|
||||
|
||||
;#___________________________________________________________________________________________________
|
||||
;****************************************************************************************************|
|
||||
; <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> |
|
||||
;----------------------------------------------------------------------------------------------------/
|
||||
;#_______________________________________________________
|
||||
;*******************************************************|
|
||||
; <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> | --------------------------------------------------------/
|
||||
|
||||
|
||||
;------------------------------------------------------------------------------------------------+
|
||||
draw_left_panel: ; <20><><EFBFBD><EFBFBD>ᮢ<EFBFBD><E1AEA2> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> SL97: <20><> ᠬ<><E1A0AC> <20><><EFBFBD><EFBFBD> <20>ࠢ<EFBFBD><E0A0A2>.
|
||||
draw_right_panel:
|
||||
;.................................................................................................
|
||||
; button_next_colorsheme
|
||||
mcall SF_DEFINE_BUTTON, <ICONX,ICONS+3>, <DRAWY,ICONS+3>, 12+BT_HIDE
|
||||
|
||||
; palitra button ; ID = 14
|
||||
mcall , ,(DRAWY+150) shl 16 + ICONS+3, 14+BT_HIDE
|
||||
mcall , ,(DRAWY+141) shl 16 + ICONS+3, 14+BT_HIDE
|
||||
|
||||
; pipet button ; ID = 15
|
||||
mcall , , (DRAWY+150) shl 16 + ICONS+3, 15+BT_HIDE
|
||||
mcall , , (DRAWY+174) shl 16 + ICONS+3, 15+BT_HIDE
|
||||
|
||||
mov ebx,[icons18bg]
|
||||
add ebx,ICONS*ICONS*4*53
|
||||
mcall SF_PUT_IMAGE_EXT, ebx, <ICONS,ICONS>, <ICONX+2,DRAWY+2>, 32, 0, 0
|
||||
|
||||
add ebx,ICONS*ICONS*4*(39-53)
|
||||
mov edx,(ICONX+2)*65536+WIN_H-90
|
||||
mov edx,(ICONX+2)*65536+DRAWY+174+2
|
||||
mcall
|
||||
|
||||
mov ebx,[icons18]
|
||||
add ebx,ICONS*ICONS*4*(53-1)
|
||||
sub edx,40
|
||||
mov edx,(ICONX+2)*65536+DRAWY+141+2
|
||||
mcall
|
||||
|
||||
stdcall DrawDeepRectangle, ICONX-1, DRAWY-1, ICONS+5, ICONS+5, [sc.work_graph], [sc.work_graph]
|
||||
stdcall DrawDeepRectangle, ICONX, DRAWY, ICONS+3, ICONS+3, [sc.work_light], [sc.work_dark]
|
||||
|
||||
stdcall DrawDeepRectangle, ICONX-1, DRAWY+109, ICONS+5, ICONS+5, [sc.work_graph], [sc.work_graph]
|
||||
stdcall DrawDeepRectangle, ICONX, DRAWY+110, ICONS+3, ICONS+3, [sc.work_dark], [sc.work_light]
|
||||
stdcall DrawDeepRectangle, ICONX+1, DRAWY+111, ICONS+1, ICONS+1, 0xFFFfff, 0xFFFfff
|
||||
stdcall DrawDeepRectangle, ICONX-1, DRAWY+140, ICONS+5, ICONS+5, [sc.work_graph], [sc.work_graph]
|
||||
stdcall DrawDeepRectangle, ICONX, DRAWY+141, ICONS+3, ICONS+3, [sc.work_dark], [sc.work_light]
|
||||
stdcall DrawDeepRectangle, ICONX+1, DRAWY+142, ICONS+1, ICONS+1, 0xFFFfff, 0xFFFfff
|
||||
|
||||
stdcall DrawDeepRectangle, ICONX-1, DRAWY+149, ICONS+5, ICONS+5, [sc.work_graph], [sc.work_graph]
|
||||
stdcall DrawDeepRectangle, ICONX, DRAWY+150, ICONS+3, ICONS+3, [sc.work_light], [sc.work_dark]
|
||||
stdcall DrawDeepRectangle, ICONX-1, DRAWY+173, ICONS+5, ICONS+5, [sc.work_graph], [sc.work_graph]
|
||||
stdcall DrawDeepRectangle, ICONX, DRAWY+174, ICONS+3, ICONS+3, [sc.work_light], [sc.work_dark]
|
||||
|
||||
;stdcall DrawRectangle3D, ICONX, DRAWY, 22, 22, [sc.work_light], [sc.work_dark] ;Leency: draw rectangle around the button, buggy now
|
||||
|
||||
;mov eax,13 ; draw rect
|
||||
;mov ebx,266 shl 16+16 ; [x] + [size]
|
||||
;mov ecx,9 shl 16+16 ; [y] + [size]
|
||||
;mov edx,0x666666 ; RGB
|
||||
;push esi ; backup esi
|
||||
;mov esi,8 ; counter=8
|
||||
;draw_lpanel: ; loop label
|
||||
; int 0x40 ; call draw black rect
|
||||
; add ecx,19 shl 16 ; move rect
|
||||
; dec esi ; decrement counter
|
||||
; cmp esi,0 ; if counter!=zero
|
||||
; jne draw_lpanel ; then goto label
|
||||
; mov esi,8 ; else counter=8
|
||||
; mov ebx,267 shl 16+14 ; [x] + [size]
|
||||
; mov ecx,10 shl 16+14 ; [y] + [size]
|
||||
; mov edx,0xF3F3F3 ; RGB
|
||||
;draw_lpanel2: ; 2 loop label
|
||||
; int 0x40 ; call draw white rect
|
||||
; add ecx,19 shl 16 ; move rect
|
||||
; dec esi ; decrement counter
|
||||
; cmp esi,0 ; if counter!=0
|
||||
; jne draw_lpanel2 ; then goto label2
|
||||
;pop esi ; restore esi
|
||||
; draw_left_arrow for button_next_colorsheme
|
||||
;mov eax,4 ; Write string
|
||||
;mov ebx,272 shl 16+13 ; [x] + [y]
|
||||
;mov ecx,0x0 ; RGB
|
||||
;mov edx,larrow ; string pointer
|
||||
;mov esi,1 ; count symbol
|
||||
;int 0x40 ; call
|
||||
;mov eax,38 ; draw line
|
||||
;mov ebx,270 shl 16+272 ; [start x] + [end x]
|
||||
;mov ecx,16 shl 16+16 ; [start y] + [end y]
|
||||
;mov edx,0x0 ; RGB
|
||||
;int 0x40 ; call
|
||||
ret ; return
|
||||
ret
|
||||
;.................................................................................................
|
||||
|
||||
|
||||
;------------------------------------------------------------------------------------------------+
|
||||
draw_bottom_panel: ; <20><><EFBFBD><EFBFBD>ᮢ<EFBFBD><E1AEA2> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
;.................................................................................................
|
||||
mcall SF_DEFINE_BUTTON, <129,90>, <WIN_H-27,16>, 16, [sc.work_button]
|
||||
mcall SF_DEFINE_BUTTON, <129,90>, <WIN_H-27,18>, 14, [sc.work_button]
|
||||
|
||||
add ebx, 100 shl 16
|
||||
add edx, 2
|
||||
@@ -408,7 +366,7 @@ draw_main:
|
||||
; Write string
|
||||
mov ecx,[sc.work_text] ; RGB
|
||||
add ecx, 0x90000000
|
||||
mcall SF_DRAW_TEXT, <35, WIN_H-26>, ,bground
|
||||
mcall SF_DRAW_TEXT, <35, WIN_H-25>, ,bground
|
||||
|
||||
mov ecx, [sc.work_button_text]
|
||||
add ecx, 0x90000000
|
||||
@@ -892,8 +850,7 @@ endp
|
||||
;****************************************************************************************************|
|
||||
; <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> |
|
||||
;----------------------------------------------------------------------------------------------------/
|
||||
circle:
|
||||
title db 'Palitra v0.77',0 ; <20>࠭<EFBFBD><E0A0AD> <20><><EFBFBD> <20>ணࠬ<E0AEA3><E0A0AC>
|
||||
title db 'Palitra v0.8',0 ; <20>࠭<EFBFBD><E0A0AD> <20><><EFBFBD> <20>ணࠬ<E0AEA3><E0A0AC>
|
||||
hidden db 'Hidden',0
|
||||
; hex db '#',0 ; <20><><EFBFBD> <20>뢮<EFBFBD><EBA2AE> <20><><EFBFBD><EFBFBD>⪨ <20><><EFBFBD> ⥪<><E2A5AA><EFBFBD>
|
||||
cname db 'RGBAx' ; <20>࠭<EFBFBD><E0A0AD> ࠧ<><E0A0A7><EFBFBD><EFBFBD> 梥⮢ (red,green,blue) x-<2D><>⪠ <20><><EFBFBD><EFBFBD><EFBFBD>
|
||||
@@ -937,7 +894,7 @@ I_END:
|
||||
cblue rb 1 ; <20>࠭<EFBFBD><E0A0AD> ᨭ<><E1A8AD> ᯥ<><E1AFA5><EFBFBD>
|
||||
calpha rb 1 ; <20>࠭<EFBFBD><E0A0AD> <20><EFBFBD><E0AEA7>筮<EFBFBD><E7ADAE><EFBFBD>
|
||||
pnext rd 1 ; <20><><EFBFBD><EFBFBD>稪 <20><>४<EFBFBD><E0A5AA>祭<EFBFBD><E7A5AD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
renmode rd 1 ; ०<><E0A5A6> <20><><EFBFBD><EFBFBD>ᮢ<EFBFBD><E1AEA2> (1-梥⮢<E6A2A5><E2AEA2> <20>奬<EFBFBD>,2-<2D><><EFBFBD><EFBFBD>⪠,3-<2D><>㣮<EFBFBD><E3A3AE><EFBFBD>)
|
||||
renmode rd 1 ; ०<><E0A5A6> <20><><EFBFBD><EFBFBD>ᮢ<EFBFBD><E1AEA2> (0-梥⮢<E6A2A5><E2AEA2> <20>奬<EFBFBD>,1-<2D><><EFBFBD><EFBFBD>⪠)
|
||||
params rb 20 ; <20><><EFBFBD><EFBFBD><EFBFBD> <20><>ࠬ<EFBFBD><E0A0AC>
|
||||
params_c rb 9 ; <20><><EFBFBD><EFBFBD> <20><><EFBFBD> 梥<><E6A2A5>
|
||||
bgimg_buf rd 1 ; buffer for a generated image
|
||||
|
@@ -2,26 +2,22 @@ DOS-866
|
||||
|
||||
<EFBFBD><EFBFBD><EFBFBD>ᠭ<EFBFBD><EFBFBD> <20><>ࠬ<EFBFBD><E0A0AC> <20><><EFBFBD> <20><><EFBFBD><EFBFBD>᪠ <20>ணࠬ<E0AEA3><E0A0AC> Palitra
|
||||
|
||||
$ <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD> <20><>ࠬ<EFBFBD><E0A0AC>
|
||||
------------------------------------------------------------------------------+
|
||||
<EFBFBD>ணࠬ<EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20>롮<EFBFBD><EBA1AE> 梥⮢ <20><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20> <20><>⠢<EFBFBD><E2A0A2><EFBFBD><EFBFBD><EFBFBD> <20><> <20><><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
<EFBFBD><EFBFBD><EFBFBD> 䮭 ࠡ<>祣<EFBFBD> <20>⮫<EFBFBD>.
|
||||
..............................................................................+
|
||||
|
||||
|
||||
$ <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20> <20><>ࠬ<EFBFBD><E0A0AC> N
|
||||
------------------------------------------------------------------------------+
|
||||
ࠢ<EFBFBD><EFBFBD>ᨫ쭮 <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD><EFBFBD> <20><>ࠬ<EFBFBD><EFBFBD> <EFBFBD><EFBFBD> <20>᪫<EFBFBD>祭<EFBFBD><EFBFBD><EFBFBD> ⮣<>, <20><><EFBFBD> 梥<EFBFBD><EFBFBD> <EFBFBD><EFBFBD> 㬮<EFBFBD>砭<EFBFBD><EFBFBD>
|
||||
<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> ᮮ⢥<E1AEAE><E2A2A5>⢮<EFBFBD><E2A2AE><EFBFBD><EFBFBD> <20><>।<EFBFBD><E0A5A4><EFBFBD><EFBFBD><EFBFBD> <20> <20><>ࠬ<EFBFBD><E0A0AC><EFBFBD><EFBFBD><EFBFBD>. <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><>ਠ<EFBFBD><E0A8A0><EFBFBD> <20><><EFBFBD><EFBFBD>᪠:
|
||||
<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><> 㬮<>砭<EFBFBD><EFBFBD> <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> ᮮ⢥<EFBFBD><EFBFBD>⢮<EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><EFBFBD>।<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20> <20><>ࠬ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>.
|
||||
<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><>ਠ<EFBFBD><E0A8A0><EFBFBD> <20><><EFBFBD><EFBFBD>᪠:
|
||||
|
||||
/sys/media/palitra N 00FF00FF 00FF0000
|
||||
/sys/media/palitra N 00F724A3 00736698
|
||||
..............................................................................+
|
||||
|
||||
|
||||
$ <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20> <20><>ࠬ<EFBFBD><E0A0AC> H
|
||||
$ <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20> <20><>ࠬ<EFBFBD><E0A0AC> H
|
||||
------------------------------------------------------------------------------+
|
||||
<EFBFBD>ணࠬ<EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>᪠<EFBFBD><E1AAA0><EFBFBD><EFBFBD> <20> hidden mode <20><><EFBFBD> <20><><EFBFBD><EFBFBD>ᮢ<EFBFBD><E1AEA2> <20><><EFBFBD><EFBFBD> <20>ਫ<EFBFBD><E0A8AB><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20> <20><><EFBFBD><EFBFBD>㦠<EFBFBD><E3A6A0>
|
||||
<EFBFBD><EFBFBD><EFBFBD> 梥<><E6A2A5> <20><> /settings/wallpaper.dat. <20><> 祣<>, <20><><EFBFBD><EFBFBD>祭<EFBFBD><EFBFBD><EFBFBD> 梥<EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD>
|
||||
<EFBFBD>ᯮ<EFBFBD>짮<EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> 䮭<> ࠡ<EFBFBD>祣<EFBFBD> <20>⮫<EFBFBD> <20>ࠤ<EFBFBD><E0A0A4><EFBFBD>⮬ <20><> 㪠<><E3AAA0><EFBFBD><EFBFBD><EFBFBD><EFBFBD> 梥⮢.
|
||||
<EFBFBD>ணࠬ<EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>᪠<EFBFBD><E1AAA0><EFBFBD><EFBFBD> <20> hidden mode <20><><EFBFBD> <20><><EFBFBD><EFBFBD>ᮢ<EFBFBD><E1AEA2> <20><><EFBFBD><EFBFBD> <20>ਫ<EFBFBD><E0A8AB><EFBFBD><EFBFBD><EFBFBD><EFBFBD>.
|
||||
<EFBFBD><EFBFBD> 祣<>, 梥<><E6A2A5> <20><>।<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20> <20><>ࠬ<EFBFBD><E0A0AC><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD> <20>ᯮ<EFBFBD>짮<EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> 䮭<>
|
||||
ࠡ<EFBFBD>祣<EFBFBD> <20>⮫<EFBFBD> <20>ࠤ<EFBFBD><E0A0A4><EFBFBD>⮬ <20><> 㪠<><E3AAA0><EFBFBD><EFBFBD><EFBFBD><EFBFBD> 梥⮢.
|
||||
|
||||
/sys/media/palitra H 00FF00FF 00FF0000
|
||||
/sys/media/palitra H 00F724A3 00736698
|
||||
..............................................................................+
|
@@ -2,7 +2,6 @@
|
||||
; DBGBOARD - a console-based debug board
|
||||
; Copyright (C) 2025 KolibriOS team
|
||||
|
||||
|
||||
format binary as ""
|
||||
use32
|
||||
org 0
|
||||
@@ -55,6 +54,7 @@ struct RING_BUFFER
|
||||
pos dd ?
|
||||
bytes_filled dd ?
|
||||
ends
|
||||
assert sizeof.RING_BUFFER = 16 ; for BSF
|
||||
|
||||
proc set_text_color stdcall uses eax ecx edx, _color
|
||||
and [_color], 0x0F
|
||||
@@ -154,7 +154,7 @@ proc print_ring_buffer stdcall uses eax ebx ecx edx esi, _rb
|
||||
add eax, edx
|
||||
mov eax, [eax]
|
||||
mov byte [chr], al
|
||||
stdcall print_next_char, chr
|
||||
stdcall print_next_char
|
||||
inc ecx
|
||||
.endw
|
||||
ret
|
||||
@@ -231,7 +231,7 @@ proc print_next_char uses ebx
|
||||
stdcall set_text_color, TEXT_COLOR_LIGHTGRAY
|
||||
mov [is_kernel_printing], 0
|
||||
.endif
|
||||
.if [is_kernel_printing]
|
||||
.if [is_kernel_printing] = 1
|
||||
.if [current_mode] = MODE_KERNEL | [current_mode] = MODE_BOTH
|
||||
invoke con_write_asciiz, prefix
|
||||
.endif
|
||||
@@ -248,7 +248,7 @@ proc print_next_char uses ebx
|
||||
inc [prefix_index]
|
||||
.endif
|
||||
.else
|
||||
.if [is_kernel_printing]
|
||||
.if [is_kernel_printing] = 1
|
||||
.if [current_mode] = MODE_KERNEL | [current_mode] = MODE_BOTH
|
||||
invoke con_write_asciiz, chr
|
||||
.endif
|
||||
@@ -317,7 +317,7 @@ start:
|
||||
xor eax, eax
|
||||
.endif
|
||||
mov [current_mode], eax
|
||||
shl eax, BSF sizeof.RING_BUFFER ; assert on sizeof, must be power of two
|
||||
shl eax, BSF sizeof.RING_BUFFER
|
||||
add eax, rb_base
|
||||
mov [current_rb], eax
|
||||
mov eax, [current_mode]
|
||||
@@ -331,7 +331,7 @@ start:
|
||||
mov dword [prefix], 0
|
||||
mov [prefix_index], 0
|
||||
mov [is_start_line], 1
|
||||
mov [is_kernel_printing], 0 ;;
|
||||
mov [is_kernel_printing], 0
|
||||
stdcall print_ring_buffer, [current_rb]
|
||||
.endif
|
||||
.endif
|
||||
|
Reference in New Issue
Block a user