mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-12-10 02:57:22 +01:00
turbopower_ipro: bugfixes, Two new examples, with full navegation across links and Backward/Forward buttons from Jordi March Nogue
git-svn-id: trunk@13043 -
This commit is contained in:
parent
7187688e75
commit
496be6ce57
14
.gitattributes
vendored
14
.gitattributes
vendored
@ -1007,6 +1007,20 @@ components/tdbf/registerdbf.pas svneol=native#text/pascal
|
||||
components/tdbf/tdbf.xpm -text svneol=native#image/x-xpixmap
|
||||
components/turbopower_ipro/Makefile svneol=native#text/plain
|
||||
components/turbopower_ipro/Makefile.fpc svneol=native#text/plain
|
||||
components/turbopower_ipro/examples/htmfileexp1.lfm svneol=native#text/plain
|
||||
components/turbopower_ipro/examples/htmfileexp1.lrs svneol=native#text/plain
|
||||
components/turbopower_ipro/examples/htmfileexp1.pas svneol=native#text/plain
|
||||
components/turbopower_ipro/examples/htmfileexp2.lfm svneol=native#text/plain
|
||||
components/turbopower_ipro/examples/htmfileexp2.lrs svneol=native#text/plain
|
||||
components/turbopower_ipro/examples/htmfileexp2.pas svneol=native#text/plain
|
||||
components/turbopower_ipro/examples/htmfileexplorer1.lpi svneol=native#text/plain
|
||||
components/turbopower_ipro/examples/htmfileexplorer1.lpr svneol=native#text/plain
|
||||
components/turbopower_ipro/examples/htmfileexplorer2.lpi svneol=native#text/plain
|
||||
components/turbopower_ipro/examples/htmfileexplorer2.lpr svneol=native#text/plain
|
||||
components/turbopower_ipro/examples/index.html svneol=native#text/plain
|
||||
components/turbopower_ipro/examples/simplepage2.html svneol=native#text/plain
|
||||
components/turbopower_ipro/for_delphi/ipHtml.dcr -text
|
||||
components/turbopower_ipro/for_delphi/iphtml.res -text
|
||||
components/turbopower_ipro/ipanim.pas svneol=native#text/pascal
|
||||
components/turbopower_ipro/ipconst.pas svneol=native#text/pascal
|
||||
components/turbopower_ipro/ipdefct.inc svneol=native#text/pascal
|
||||
|
||||
173
components/turbopower_ipro/examples/htmfileexp1.lfm
Normal file
173
components/turbopower_ipro/examples/htmfileexp1.lfm
Normal file
@ -0,0 +1,173 @@
|
||||
object FHtmFileExp1: TFHtmFileExp1
|
||||
Left = 454
|
||||
Height = 327
|
||||
Top = 373
|
||||
Width = 569
|
||||
HorzScrollBar.Page = 568
|
||||
VertScrollBar.Page = 326
|
||||
ActiveControl = B_OpenHTMLFile
|
||||
Caption = 'Example 1 for turbopower: HTM File Explorer'
|
||||
OnCreate = FormCreate
|
||||
OnDestroy = FormDestroy
|
||||
object IpHtmlPanel1: TIpHtmlPanel
|
||||
Height = 285
|
||||
Top = 42
|
||||
Width = 569
|
||||
Align = alClient
|
||||
FixedTypeface = 'Courier New'
|
||||
DefaultTypeFace = 'default'
|
||||
FactBAParag = 0.5
|
||||
PrintSettings.MarginLeft = 0.5
|
||||
PrintSettings.MarginTop = 0.5
|
||||
PrintSettings.MarginRight = 0.5
|
||||
PrintSettings.MarginBottom = 0.5
|
||||
OnHotClick = IpHtmlPanel1HotClick
|
||||
end
|
||||
object P_Top: TPanel
|
||||
Height = 42
|
||||
Width = 569
|
||||
Align = alTop
|
||||
TabOrder = 0
|
||||
object SB_GoBackward: TSpeedButton
|
||||
Left = 176
|
||||
Height = 25
|
||||
Top = 8
|
||||
Width = 25
|
||||
Color = clBtnFace
|
||||
Enabled = False
|
||||
Glyph.Data = {
|
||||
36060000424D3606000000000000360400002800000020000000100000000100
|
||||
0800000000000002000000000000000000000000000000000000000000000000
|
||||
80000080000000808000800000008000800080800000C0C0C000C0DCC000F0CA
|
||||
A6000020400000206000002080000020A0000020C0000020E000004000000040
|
||||
20000040400000406000004080000040A0000040C0000040E000006000000060
|
||||
20000060400000606000006080000060A0000060C0000060E000008000000080
|
||||
20000080400000806000008080000080A0000080C0000080E00000A0000000A0
|
||||
200000A0400000A0600000A0800000A0A00000A0C00000A0E00000C0000000C0
|
||||
200000C0400000C0600000C0800000C0A00000C0C00000C0E00000E0000000E0
|
||||
200000E0400000E0600000E0800000E0A00000E0C00000E0E000400000004000
|
||||
20004000400040006000400080004000A0004000C0004000E000402000004020
|
||||
20004020400040206000402080004020A0004020C0004020E000404000004040
|
||||
20004040400040406000404080004040A0004040C0004040E000406000004060
|
||||
20004060400040606000406080004060A0004060C0004060E000408000004080
|
||||
20004080400040806000408080004080A0004080C0004080E00040A0000040A0
|
||||
200040A0400040A0600040A0800040A0A00040A0C00040A0E00040C0000040C0
|
||||
200040C0400040C0600040C0800040C0A00040C0C00040C0E00040E0000040E0
|
||||
200040E0400040E0600040E0800040E0A00040E0C00040E0E000800000008000
|
||||
20008000400080006000800080008000A0008000C0008000E000802000008020
|
||||
20008020400080206000802080008020A0008020C0008020E000804000008040
|
||||
20008040400080406000804080008040A0008040C0008040E000806000008060
|
||||
20008060400080606000806080008060A0008060C0008060E000808000008080
|
||||
20008080400080806000808080008080A0008080C0008080E00080A0000080A0
|
||||
200080A0400080A0600080A0800080A0A00080A0C00080A0E00080C0000080C0
|
||||
200080C0400080C0600080C0800080C0A00080C0C00080C0E00080E0000080E0
|
||||
200080E0400080E0600080E0800080E0A00080E0C00080E0E000C0000000C000
|
||||
2000C0004000C0006000C0008000C000A000C000C000C000E000C0200000C020
|
||||
2000C0204000C0206000C0208000C020A000C020C000C020E000C0400000C040
|
||||
2000C0404000C0406000C0408000C040A000C040C000C040E000C0600000C060
|
||||
2000C0604000C0606000C0608000C060A000C060C000C060E000C0800000C080
|
||||
2000C0804000C0806000C0808000C080A000C080C000C080E000C0A00000C0A0
|
||||
2000C0A04000C0A06000C0A08000C0A0A000C0A0C000C0A0E000C0C00000C0C0
|
||||
2000C0C04000C0C06000C0C08000C0C0A000F0FBFF00A4A0A000808080000000
|
||||
FF0000FF000000FFFF00FF000000FF00FF00FFFF0000FFFFFF00FDFDFDFDFDFD
|
||||
FDF5F5FDFDFDFDFDFDFDFDFDFDFDFDFDFD0707FDFDFDFDFDFDFDFDFDFDFDFDFD
|
||||
B51111FDFDFDFDFDFDFDFDFDFDFDFDFD07F7F7FDFDFDFDFDFDFDFDFDFDFDFDB5
|
||||
196219FDFDFDFDFDFDFDFDFDFDFDFD07F707F7FDFDFDFDFDFDFDFDFDFDFDAC11
|
||||
627362FDFDFDFDFDFDFDFDFDFDFD07F7070707FDFDFDFDFDFDFDFDFDFDAC1962
|
||||
737361B4B4F7ACADF7FDFDFDFD07F707070707070707070707FDFDFDAC1162B3
|
||||
696A61181919191951FDFDFD07F70707070707F7F7F7F7F7F7FDFDAC1162BCB3
|
||||
69697272737373B462FDFD07F7070707F707070707070707F7FDB41162B3B3B3
|
||||
B2686969727272B462FD07F7070707070707070707070707F7FD616AF4B3B3B3
|
||||
BB696869696969B361FDF7070707070707F7070707070707F7FDFD61AABBB3B4
|
||||
BCBB6968696969BB61FDFDF7070707070707F7F7F7F7F707F7FDFDFD61AABCBC
|
||||
B4F4BCBCBCBCBCBC61FDFDFDF70707070707070707070707F7FDFDFDFD61AAF4
|
||||
B4F561616162616262FDFDFDFDF707070707F7F7F7F7F7F7F7FDFDFDFDFD61AA
|
||||
BCF561FDFDFDFDFDFDFDFDFDFDFDF7070707F7FDFDFDFDFDFDFDFDFDFDFDFD61
|
||||
AAF462FDFDFDFDFDFDFDFDFDFDFDFDF70707F7FDFDFDFDFDFDFDFDFDFDFDFDFD
|
||||
61AA61FDFDFDFDFDFDFDFDFDFDFDFDFDF707F7FDFDFDFDFDFDFDFDFDFDFDFDFD
|
||||
FD6161FDFDFDFDFDFDFDFDFDFDFDFDFDFDF7F7FDFDFDFDFDFDFD
|
||||
}
|
||||
NumGlyphs = 2
|
||||
OnClick = SB_GoBackwardClick
|
||||
end
|
||||
object SB_GoForward: TSpeedButton
|
||||
Left = 208
|
||||
Height = 25
|
||||
Top = 8
|
||||
Width = 25
|
||||
Color = clBtnFace
|
||||
Enabled = False
|
||||
Glyph.Data = {
|
||||
36060000424D3606000000000000360400002800000020000000100000000100
|
||||
0800000000000002000000000000000000000000000000000000000000000000
|
||||
80000080000000808000800000008000800080800000C0C0C000C0DCC000F0CA
|
||||
A6000020400000206000002080000020A0000020C0000020E000004000000040
|
||||
20000040400000406000004080000040A0000040C0000040E000006000000060
|
||||
20000060400000606000006080000060A0000060C0000060E000008000000080
|
||||
20000080400000806000008080000080A0000080C0000080E00000A0000000A0
|
||||
200000A0400000A0600000A0800000A0A00000A0C00000A0E00000C0000000C0
|
||||
200000C0400000C0600000C0800000C0A00000C0C00000C0E00000E0000000E0
|
||||
200000E0400000E0600000E0800000E0A00000E0C00000E0E000400000004000
|
||||
20004000400040006000400080004000A0004000C0004000E000402000004020
|
||||
20004020400040206000402080004020A0004020C0004020E000404000004040
|
||||
20004040400040406000404080004040A0004040C0004040E000406000004060
|
||||
20004060400040606000406080004060A0004060C0004060E000408000004080
|
||||
20004080400040806000408080004080A0004080C0004080E00040A0000040A0
|
||||
200040A0400040A0600040A0800040A0A00040A0C00040A0E00040C0000040C0
|
||||
200040C0400040C0600040C0800040C0A00040C0C00040C0E00040E0000040E0
|
||||
200040E0400040E0600040E0800040E0A00040E0C00040E0E000800000008000
|
||||
20008000400080006000800080008000A0008000C0008000E000802000008020
|
||||
20008020400080206000802080008020A0008020C0008020E000804000008040
|
||||
20008040400080406000804080008040A0008040C0008040E000806000008060
|
||||
20008060400080606000806080008060A0008060C0008060E000808000008080
|
||||
20008080400080806000808080008080A0008080C0008080E00080A0000080A0
|
||||
200080A0400080A0600080A0800080A0A00080A0C00080A0E00080C0000080C0
|
||||
200080C0400080C0600080C0800080C0A00080C0C00080C0E00080E0000080E0
|
||||
200080E0400080E0600080E0800080E0A00080E0C00080E0E000C0000000C000
|
||||
2000C0004000C0006000C0008000C000A000C000C000C000E000C0200000C020
|
||||
2000C0204000C0206000C0208000C020A000C020C000C020E000C0400000C040
|
||||
2000C0404000C0406000C0408000C040A000C040C000C040E000C0600000C060
|
||||
2000C0604000C0606000C0608000C060A000C060C000C060E000C0800000C080
|
||||
2000C0804000C0806000C0808000C080A000C080C000C080E000C0A00000C0A0
|
||||
2000C0A04000C0A06000C0A08000C0A0A000C0A0C000C0A0E000C0C00000C0C0
|
||||
2000C0C04000C0C06000C0C08000C0C0A000F0FBFF00A4A0A000808080000000
|
||||
FF0000FF000000FFFF00FF000000FF00FF00FFFF0000FFFFFF00FDFDFDFDFDFD
|
||||
FDF5F5FDFDFDFDFDFDFDFDFDFDFDFDFDFD0707FDFDFDFDFDFDFDFDFDFDFDFDFD
|
||||
FD1111B5FDFDFDFDFDFDFDFDFDFDFDFDFDF7F707FDFDFDFDFDFDFDFDFDFDFDFD
|
||||
FD196219B5FDFDFDFDFDFDFDFDFDFDFDFDF707F707FDFDFDFDFDFDFDFDFDFDFD
|
||||
FD62736211ACFDFDFDFDFDFDFDFDFDFDFD070707F707FDFDFDFDFDF7ADACF7B4
|
||||
B46173736219ACFDFDFDFD07070707070707070707F707FDFDFDFD5119191919
|
||||
18616A69B36211ACFDFDFDF7F7F7F7F7F70707070707F707FDFDFD62B4737373
|
||||
72726969B3BC6211ACFDFDF707070707070707F7070707F707FDFD62B4727272
|
||||
696968B2B3B3B36211B4FDF7070707070707070707070707F707FD61B3696969
|
||||
696869BBB3B3B3F46A61FDF707070707070707070707070707F7FD61BB696969
|
||||
6869BBBCB4B3BBAA61FDFDF70707F707F7F7070707070707F7FDFD61BCBCBCBC
|
||||
BCBCF4B4BCBCAA61FDFDFDF70707070707070707070707F7FDFDFD6262616261
|
||||
6161F5B4F4AA61FDFDFDFDF7F707F7F707F707070707F7FDFDFDFDFDFDFDFDFD
|
||||
FD61F5BCAA61FDFDFDFDFDFDFDFDFDFDFDF7070707F7FDFDFDFDFDFDFDFDFDFD
|
||||
FD62F4AA61FDFDFDFDFDFDFDFDFDFDFDFDF70707F7FDFDFDFDFDFDFDFDFDFDFD
|
||||
FD61AA61FDFDFDFDFDFDFDFDFDFDFDFDFDF707F7FDFDFDFDFDFDFDFDFDFDFDFD
|
||||
FD6161FDFDFDFDFDFDFDFDFDFDFDFDFDFDF7F7FDFDFDFDFDFDFD
|
||||
}
|
||||
NumGlyphs = 2
|
||||
OnClick = SB_GoForwardClick
|
||||
end
|
||||
object B_OpenHTMLFile: TButton
|
||||
Left = 16
|
||||
Height = 26
|
||||
Top = 8
|
||||
Width = 152
|
||||
BorderSpacing.InnerBorder = 4
|
||||
Caption = 'Open HTML File'
|
||||
OnClick = B_OpenHTMLFileClick
|
||||
TabOrder = 0
|
||||
end
|
||||
end
|
||||
object OpenDialog1: TOpenDialog
|
||||
Title = 'Open existing file'
|
||||
Filter = 'Web Pages|*.html;*.htm'
|
||||
FilterIndex = 0
|
||||
left = 26
|
||||
top = 93
|
||||
end
|
||||
end
|
||||
154
components/turbopower_ipro/examples/htmfileexp1.lrs
Normal file
154
components/turbopower_ipro/examples/htmfileexp1.lrs
Normal file
@ -0,0 +1,154 @@
|
||||
{ Das ist eine automatisch erzeugte Lazarus-Ressourcendatei }
|
||||
|
||||
LazarusResources.Add('TFHtmFileExp1','FORMDATA',[
|
||||
'TPF0'#13'TFHtmFileExp1'#12'FHtmFileExp1'#4'Left'#3#198#1#6'Height'#3'G'#1#3
|
||||
+'Top'#3'u'#1#5'Width'#3'9'#2#18'HorzScrollBar.Page'#3'8'#2#18'VertScrollBar.'
|
||||
+'Page'#3'F'#1#13'ActiveControl'#7#14'B_OpenHTMLFile'#7'Caption'#6'+Example 1'
|
||||
+' for turbopower: HTM File Explorer'#8'OnCreate'#7#10'FormCreate'#9'OnDestro'
|
||||
+'y'#7#11'FormDestroy'#0#12'TIpHtmlPanel'#12'IpHtmlPanel1'#6'Height'#3#29#1#3
|
||||
+'Top'#2'*'#5'Width'#3'9'#2#5'Align'#7#8'alClient'#13'FixedTypeface'#6#11'Cou'
|
||||
+'rier New'#15'DefaultTypeFace'#6#7'default'#11'FactBAParag'#5#0#0#0#0#0#0#0
|
||||
+#128#254'?'#24'PrintSettings.MarginLeft'#5#0#0#0#0#0#0#0#128#254'?'#23'Print'
|
||||
+'Settings.MarginTop'#5#0#0#0#0#0#0#0#128#254'?'#25'PrintSettings.MarginRight'
|
||||
+#5#0#0#0#0#0#0#0#128#254'?'#26'PrintSettings.MarginBottom'#5#0#0#0#0#0#0#0
|
||||
+#128#254'?'#10'OnHotClick'#7#20'IpHtmlPanel1HotClick'#0#0#6'TPanel'#5'P_Top'
|
||||
+#6'Height'#2'*'#5'Width'#3'9'#2#5'Align'#7#5'alTop'#8'TabOrder'#2#0#0#12'TSp'
|
||||
+'eedButton'#13'SB_GoBackward'#4'Left'#3#176#0#6'Height'#2#25#3'Top'#2#8#5'Wi'
|
||||
+'dth'#2#25#5'Color'#7#9'clBtnFace'#7'Enabled'#8#10'Glyph.Data'#10':'#6#0#0'6'
|
||||
+#6#0#0'BM6'#6#0#0#0#0#0#0'6'#4#0#0'('#0#0#0' '#0#0#0#16#0#0#0#1#0#8#0#0#0#0#0
|
||||
+#0#2#0#0#0#0#0#0#0#0#0#0#0#0#0#0#0#0#0#0#0#0#0#0#0#0#128#0#0#128#0#0#0#128
|
||||
+#128#0#128#0#0#0#128#0#128#0#128#128#0#0#192#192#192#0#192#220#192#0#240#202
|
||||
+#166#0#0' @'#0#0' `'#0#0' '#128#0#0' '#160#0#0' '#192#0#0' '#224#0#0'@'#0#0#0
|
||||
+'@ '#0#0'@@'#0#0'@`'#0#0'@'#128#0#0'@'#160#0#0'@'#192#0#0'@'#224#0#0'`'#0#0#0
|
||||
+'` '#0#0'`@'#0#0'``'#0#0'`'#128#0#0'`'#160#0#0'`'#192#0#0'`'#224#0#0#128#0#0
|
||||
+#0#128' '#0#0#128'@'#0#0#128'`'#0#0#128#128#0#0#128#160#0#0#128#192#0#0#128
|
||||
+#224#0#0#160#0#0#0#160' '#0#0#160'@'#0#0#160'`'#0#0#160#128#0#0#160#160#0#0
|
||||
+#160#192#0#0#160#224#0#0#192#0#0#0#192' '#0#0#192'@'#0#0#192'`'#0#0#192#128#0
|
||||
+#0#192#160#0#0#192#192#0#0#192#224#0#0#224#0#0#0#224' '#0#0#224'@'#0#0#224'`'
|
||||
+#0#0#224#128#0#0#224#160#0#0#224#192#0#0#224#224#0'@'#0#0#0'@'#0' '#0'@'#0'@'
|
||||
+#0'@'#0'`'#0'@'#0#128#0'@'#0#160#0'@'#0#192#0'@'#0#224#0'@ '#0#0'@ '#0'@ @'
|
||||
+#0'@ `'#0'@ '#128#0'@ '#160#0'@ '#192#0'@ '#224#0'@@'#0#0'@@ '#0'@@@'#0'@@`'
|
||||
+#0'@@'#128#0'@@'#160#0'@@'#192#0'@@'#224#0'@`'#0#0'@` '#0'@`@'#0'@``'#0'@`'
|
||||
+#128#0'@`'#160#0'@`'#192#0'@`'#224#0'@'#128#0#0'@'#128' '#0'@'#128'@'#0'@'
|
||||
+#128'`'#0'@'#128#128#0'@'#128#160#0'@'#128#192#0'@'#128#224#0'@'#160#0#0'@'
|
||||
+#160' '#0'@'#160'@'#0'@'#160'`'#0'@'#160#128#0'@'#160#160#0'@'#160#192#0'@'
|
||||
+#160#224#0'@'#192#0#0'@'#192' '#0'@'#192'@'#0'@'#192'`'#0'@'#192#128#0'@'#192
|
||||
+#160#0'@'#192#192#0'@'#192#224#0'@'#224#0#0'@'#224' '#0'@'#224'@'#0'@'#224'`'
|
||||
+#0'@'#224#128#0'@'#224#160#0'@'#224#192#0'@'#224#224#0#128#0#0#0#128#0' '#0
|
||||
+#128#0'@'#0#128#0'`'#0#128#0#128#0#128#0#160#0#128#0#192#0#128#0#224#0#128' '
|
||||
+#0#0#128' '#0#128' @'#0#128' `'#0#128' '#128#0#128' '#160#0#128' '#192#0#128
|
||||
+' '#224#0#128'@'#0#0#128'@ '#0#128'@@'#0#128'@`'#0#128'@'#128#0#128'@'#160#0
|
||||
+#128'@'#192#0#128'@'#224#0#128'`'#0#0#128'` '#0#128'`@'#0#128'``'#0#128'`'
|
||||
+#128#0#128'`'#160#0#128'`'#192#0#128'`'#224#0#128#128#0#0#128#128' '#0#128
|
||||
+#128'@'#0#128#128'`'#0#128#128#128#0#128#128#160#0#128#128#192#0#128#128#224
|
||||
+#0#128#160#0#0#128#160' '#0#128#160'@'#0#128#160'`'#0#128#160#128#0#128#160
|
||||
+#160#0#128#160#192#0#128#160#224#0#128#192#0#0#128#192' '#0#128#192'@'#0#128
|
||||
+#192'`'#0#128#192#128#0#128#192#160#0#128#192#192#0#128#192#224#0#128#224#0#0
|
||||
+#128#224' '#0#128#224'@'#0#128#224'`'#0#128#224#128#0#128#224#160#0#128#224
|
||||
+#192#0#128#224#224#0#192#0#0#0#192#0' '#0#192#0'@'#0#192#0'`'#0#192#0#128#0
|
||||
+#192#0#160#0#192#0#192#0#192#0#224#0#192' '#0#0#192' '#0#192' @'#0#192' `'#0
|
||||
+#192' '#128#0#192' '#160#0#192' '#192#0#192' '#224#0#192'@'#0#0#192'@ '#0#192
|
||||
+'@@'#0#192'@`'#0#192'@'#128#0#192'@'#160#0#192'@'#192#0#192'@'#224#0#192'`'#0
|
||||
+#0#192'` '#0#192'`@'#0#192'``'#0#192'`'#128#0#192'`'#160#0#192'`'#192#0#192
|
||||
+'`'#224#0#192#128#0#0#192#128' '#0#192#128'@'#0#192#128'`'#0#192#128#128#0
|
||||
+#192#128#160#0#192#128#192#0#192#128#224#0#192#160#0#0#192#160' '#0#192#160
|
||||
+'@'#0#192#160'`'#0#192#160#128#0#192#160#160#0#192#160#192#0#192#160#224#0
|
||||
+#192#192#0#0#192#192' '#0#192#192'@'#0#192#192'`'#0#192#192#128#0#192#192#160
|
||||
+#0#240#251#255#0#164#160#160#0#128#128#128#0#0#0#255#0#0#255#0#0#0#255#255#0
|
||||
+#255#0#0#0#255#0#255#0#255#255#0#0#255#255#255#0#253#253#253#253#253#253#253
|
||||
+#245#245#253#253#253#253#253#253#253#253#253#253#253#253#253#253#7#7#253#253
|
||||
+#253#253#253#253#253#253#253#253#253#253#253#181#17#17#253#253#253#253#253
|
||||
+#253#253#253#253#253#253#253#253#7#247#247#253#253#253#253#253#253#253#253
|
||||
+#253#253#253#253#181#25'b'#25#253#253#253#253#253#253#253#253#253#253#253#253
|
||||
+#7#247#7#247#253#253#253#253#253#253#253#253#253#253#253#172#17'bsb'#253#253
|
||||
+#253#253#253#253#253#253#253#253#253#7#247#7#7#7#253#253#253#253#253#253#253
|
||||
+#253#253#253#172#25'bssa'#180#180#247#172#173#247#253#253#253#253#7#247#7#7#7
|
||||
+#7#7#7#7#7#7#7#253#253#253#172#17'b'#179'ija'#24#25#25#25#25'Q'#253#253#253#7
|
||||
+#247#7#7#7#7#7#247#247#247#247#247#247#253#253#172#17'b'#188#179'iirrsss'#180
|
||||
,'b'#253#253#7#247#7#7#7#247#7#7#7#7#7#7#7#247#253#180#17'b'#179#179#179#178
|
||||
+'hiirrr'#180'b'#253#7#247#7#7#7#7#7#7#7#7#7#7#7#7#247#253'aj'#244#179#179#179
|
||||
+#187'ihiiii'#179'a'#253#247#7#7#7#7#7#7#247#7#7#7#7#7#7#247#253#253'a'#170
|
||||
+#187#179#180#188#187'ihiii'#187'a'#253#253#247#7#7#7#7#7#7#247#247#247#247
|
||||
+#247#7#247#253#253#253'a'#170#188#188#180#244#188#188#188#188#188#188'a'#253
|
||||
+#253#253#247#7#7#7#7#7#7#7#7#7#7#7#247#253#253#253#253'a'#170#244#180#245'aa'
|
||||
+'ababb'#253#253#253#253#247#7#7#7#7#247#247#247#247#247#247#247#253#253#253
|
||||
+#253#253'a'#170#188#245'a'#253#253#253#253#253#253#253#253#253#253#253#247#7
|
||||
+#7#7#247#253#253#253#253#253#253#253#253#253#253#253#253'a'#170#244'b'#253
|
||||
+#253#253#253#253#253#253#253#253#253#253#253#247#7#7#247#253#253#253#253#253
|
||||
+#253#253#253#253#253#253#253#253'a'#170'a'#253#253#253#253#253#253#253#253
|
||||
+#253#253#253#253#253#247#7#247#253#253#253#253#253#253#253#253#253#253#253
|
||||
+#253#253#253'aa'#253#253#253#253#253#253#253#253#253#253#253#253#253#253#247
|
||||
+#247#253#253#253#253#253#253#253#9'NumGlyphs'#2#2#7'OnClick'#7#18'SB_GoBackw'
|
||||
+'ardClick'#0#0#12'TSpeedButton'#12'SB_GoForward'#4'Left'#3#208#0#6'Height'#2
|
||||
+#25#3'Top'#2#8#5'Width'#2#25#5'Color'#7#9'clBtnFace'#7'Enabled'#8#10'Glyph.D'
|
||||
+'ata'#10':'#6#0#0'6'#6#0#0'BM6'#6#0#0#0#0#0#0'6'#4#0#0'('#0#0#0' '#0#0#0#16#0
|
||||
+#0#0#1#0#8#0#0#0#0#0#0#2#0#0#0#0#0#0#0#0#0#0#0#0#0#0#0#0#0#0#0#0#0#0#0#0#128
|
||||
+#0#0#128#0#0#0#128#128#0#128#0#0#0#128#0#128#0#128#128#0#0#192#192#192#0#192
|
||||
+#220#192#0#240#202#166#0#0' @'#0#0' `'#0#0' '#128#0#0' '#160#0#0' '#192#0#0
|
||||
+' '#224#0#0'@'#0#0#0'@ '#0#0'@@'#0#0'@`'#0#0'@'#128#0#0'@'#160#0#0'@'#192#0#0
|
||||
+'@'#224#0#0'`'#0#0#0'` '#0#0'`@'#0#0'``'#0#0'`'#128#0#0'`'#160#0#0'`'#192#0#0
|
||||
+'`'#224#0#0#128#0#0#0#128' '#0#0#128'@'#0#0#128'`'#0#0#128#128#0#0#128#160#0
|
||||
+#0#128#192#0#0#128#224#0#0#160#0#0#0#160' '#0#0#160'@'#0#0#160'`'#0#0#160#128
|
||||
+#0#0#160#160#0#0#160#192#0#0#160#224#0#0#192#0#0#0#192' '#0#0#192'@'#0#0#192
|
||||
+'`'#0#0#192#128#0#0#192#160#0#0#192#192#0#0#192#224#0#0#224#0#0#0#224' '#0#0
|
||||
+#224'@'#0#0#224'`'#0#0#224#128#0#0#224#160#0#0#224#192#0#0#224#224#0'@'#0#0#0
|
||||
+'@'#0' '#0'@'#0'@'#0'@'#0'`'#0'@'#0#128#0'@'#0#160#0'@'#0#192#0'@'#0#224#0'@'
|
||||
+' '#0#0'@ '#0'@ @'#0'@ `'#0'@ '#128#0'@ '#160#0'@ '#192#0'@ '#224#0'@@'#0#0
|
||||
+'@@ '#0'@@@'#0'@@`'#0'@@'#128#0'@@'#160#0'@@'#192#0'@@'#224#0'@`'#0#0'@` '#0
|
||||
+'@`@'#0'@``'#0'@`'#128#0'@`'#160#0'@`'#192#0'@`'#224#0'@'#128#0#0'@'#128' '#0
|
||||
+'@'#128'@'#0'@'#128'`'#0'@'#128#128#0'@'#128#160#0'@'#128#192#0'@'#128#224#0
|
||||
+'@'#160#0#0'@'#160' '#0'@'#160'@'#0'@'#160'`'#0'@'#160#128#0'@'#160#160#0'@'
|
||||
+#160#192#0'@'#160#224#0'@'#192#0#0'@'#192' '#0'@'#192'@'#0'@'#192'`'#0'@'#192
|
||||
+#128#0'@'#192#160#0'@'#192#192#0'@'#192#224#0'@'#224#0#0'@'#224' '#0'@'#224
|
||||
+'@'#0'@'#224'`'#0'@'#224#128#0'@'#224#160#0'@'#224#192#0'@'#224#224#0#128#0#0
|
||||
+#0#128#0' '#0#128#0'@'#0#128#0'`'#0#128#0#128#0#128#0#160#0#128#0#192#0#128#0
|
||||
+#224#0#128' '#0#0#128' '#0#128' @'#0#128' `'#0#128' '#128#0#128' '#160#0#128
|
||||
+' '#192#0#128' '#224#0#128'@'#0#0#128'@ '#0#128'@@'#0#128'@`'#0#128'@'#128#0
|
||||
+#128'@'#160#0#128'@'#192#0#128'@'#224#0#128'`'#0#0#128'` '#0#128'`@'#0#128'`'
|
||||
+'`'#0#128'`'#128#0#128'`'#160#0#128'`'#192#0#128'`'#224#0#128#128#0#0#128#128
|
||||
+' '#0#128#128'@'#0#128#128'`'#0#128#128#128#0#128#128#160#0#128#128#192#0#128
|
||||
+#128#224#0#128#160#0#0#128#160' '#0#128#160'@'#0#128#160'`'#0#128#160#128#0
|
||||
+#128#160#160#0#128#160#192#0#128#160#224#0#128#192#0#0#128#192' '#0#128#192
|
||||
+'@'#0#128#192'`'#0#128#192#128#0#128#192#160#0#128#192#192#0#128#192#224#0
|
||||
+#128#224#0#0#128#224' '#0#128#224'@'#0#128#224'`'#0#128#224#128#0#128#224#160
|
||||
+#0#128#224#192#0#128#224#224#0#192#0#0#0#192#0' '#0#192#0'@'#0#192#0'`'#0#192
|
||||
+#0#128#0#192#0#160#0#192#0#192#0#192#0#224#0#192' '#0#0#192' '#0#192' @'#0
|
||||
+#192' `'#0#192' '#128#0#192' '#160#0#192' '#192#0#192' '#224#0#192'@'#0#0#192
|
||||
+'@ '#0#192'@@'#0#192'@`'#0#192'@'#128#0#192'@'#160#0#192'@'#192#0#192'@'#224
|
||||
+#0#192'`'#0#0#192'` '#0#192'`@'#0#192'``'#0#192'`'#128#0#192'`'#160#0#192'`'
|
||||
+#192#0#192'`'#224#0#192#128#0#0#192#128' '#0#192#128'@'#0#192#128'`'#0#192
|
||||
+#128#128#0#192#128#160#0#192#128#192#0#192#128#224#0#192#160#0#0#192#160' '#0
|
||||
+#192#160'@'#0#192#160'`'#0#192#160#128#0#192#160#160#0#192#160#192#0#192#160
|
||||
+#224#0#192#192#0#0#192#192' '#0#192#192'@'#0#192#192'`'#0#192#192#128#0#192
|
||||
+#192#160#0#240#251#255#0#164#160#160#0#128#128#128#0#0#0#255#0#0#255#0#0#0
|
||||
+#255#255#0#255#0#0#0#255#0#255#0#255#255#0#0#255#255#255#0#253#253#253#253
|
||||
+#253#253#253#245#245#253#253#253#253#253#253#253#253#253#253#253#253#253#253
|
||||
+#7#7#253#253#253#253#253#253#253#253#253#253#253#253#253#253#17#17#181#253
|
||||
+#253#253#253#253#253#253#253#253#253#253#253#253#247#247#7#253#253#253#253
|
||||
+#253#253#253#253#253#253#253#253#253#25'b'#25#181#253#253#253#253#253#253#253
|
||||
+#253#253#253#253#253#247#7#247#7#253#253#253#253#253#253#253#253#253#253#253
|
||||
+#253'bsb'#17#172#253#253#253#253#253#253#253#253#253#253#253#7#7#7#247#7#253
|
||||
+#253#253#253#253#247#173#172#247#180#180'assb'#25#172#253#253#253#253#7#7#7#7
|
||||
,#7#7#7#7#7#7#247#7#253#253#253#253'Q'#25#25#25#25#24'aji'#179'b'#17#172#253
|
||||
+#253#253#247#247#247#247#247#247#7#7#7#7#7#247#7#253#253#253'b'#180'sssrrii'
|
||||
+#179#188'b'#17#172#253#253#247#7#7#7#7#7#7#7#247#7#7#7#247#7#253#253'b'#180
|
||||
+'rrriih'#178#179#179#179'b'#17#180#253#247#7#7#7#7#7#7#7#7#7#7#7#7#247#7#253
|
||||
+'a'#179'iiiihi'#187#179#179#179#244'ja'#253#247#7#7#7#7#7#7#7#7#7#7#7#7#7#247
|
||||
+#253'a'#187'iiihi'#187#188#180#179#187#170'a'#253#253#247#7#7#247#7#247#247#7
|
||||
+#7#7#7#7#7#247#253#253'a'#188#188#188#188#188#188#244#180#188#188#170'a'#253
|
||||
+#253#253#247#7#7#7#7#7#7#7#7#7#7#7#247#253#253#253'bbabaaa'#245#180#244#170
|
||||
+'a'#253#253#253#253#247#247#7#247#247#7#247#7#7#7#7#247#253#253#253#253#253
|
||||
+#253#253#253#253#253'a'#245#188#170'a'#253#253#253#253#253#253#253#253#253
|
||||
+#253#253#247#7#7#7#247#253#253#253#253#253#253#253#253#253#253#253'b'#244#170
|
||||
+'a'#253#253#253#253#253#253#253#253#253#253#253#253#247#7#7#247#253#253#253
|
||||
+#253#253#253#253#253#253#253#253#253'a'#170'a'#253#253#253#253#253#253#253
|
||||
+#253#253#253#253#253#253#247#7#247#253#253#253#253#253#253#253#253#253#253
|
||||
+#253#253#253'aa'#253#253#253#253#253#253#253#253#253#253#253#253#253#253#247
|
||||
+#247#253#253#253#253#253#253#253#9'NumGlyphs'#2#2#7'OnClick'#7#17'SB_GoForwa'
|
||||
+'rdClick'#0#0#7'TButton'#14'B_OpenHTMLFile'#4'Left'#2#16#6'Height'#2#26#3'To'
|
||||
+'p'#2#8#5'Width'#3#152#0#25'BorderSpacing.InnerBorder'#2#4#7'Caption'#6#14'O'
|
||||
+'pen HTML File'#7'OnClick'#7#19'B_OpenHTMLFileClick'#8'TabOrder'#2#0#0#0#0#11
|
||||
+'TOpenDialog'#11'OpenDialog1'#5'Title'#6#18'Open existing file'#6'Filter'#6
|
||||
+#22'Web Pages|*.html;*.htm'#11'FilterIndex'#2#0#4'left'#2#26#3'top'#2']'#0#0
|
||||
+#0
|
||||
]);
|
||||
293
components/turbopower_ipro/examples/htmfileexp1.pas
Normal file
293
components/turbopower_ipro/examples/htmfileexp1.pas
Normal file
@ -0,0 +1,293 @@
|
||||
unit HtmFileExp1;
|
||||
|
||||
{$mode objfpc}{$H+}
|
||||
|
||||
{.$define UsePreview}
|
||||
{$define UseJPEG}
|
||||
{$IFDEF LCL}
|
||||
{$DEFINE IP_LAZARUS}
|
||||
{$ENDIF}
|
||||
|
||||
interface
|
||||
|
||||
uses
|
||||
Classes, SysUtils, LResources, Forms, Controls, Graphics, Dialogs, Buttons,
|
||||
{$IFDEF IP_LAZARUS}
|
||||
{$ifdef UseJPEG}
|
||||
LazJpeg,
|
||||
{$endif}
|
||||
{$ifdef UsePreview}
|
||||
OsPrinters,
|
||||
{$endif}
|
||||
{$ELSE}
|
||||
GIFImage,
|
||||
JPeg,
|
||||
ImageDLLLoader, PNGLoader, LinarBitmap, //from ImageFileLib of Michael Vinther: http://www.logicnet.dk/lib/
|
||||
{$ENDIF}
|
||||
IpHtml, ExtCtrls, StdCtrls;
|
||||
|
||||
type
|
||||
TSimpleIpHtml = class(TIpHtml)
|
||||
public
|
||||
property OnGetImageX;
|
||||
end;
|
||||
|
||||
TPst = class(TObject)
|
||||
Position: Integer;
|
||||
end;
|
||||
|
||||
{ TFHtmFileExp1 }
|
||||
|
||||
TFHtmFileExp1 = class(TForm)
|
||||
B_OpenHTMLFile: TButton;
|
||||
IpHtmlPanel1: TIpHtmlPanel;
|
||||
OpenDialog1: TOpenDialog;
|
||||
P_Top: TPanel;
|
||||
SB_GoBackward: TSpeedButton;
|
||||
SB_GoForward: TSpeedButton;
|
||||
procedure B_OpenHTMLFileClick(Sender: TObject);
|
||||
procedure FormCreate(Sender: TObject);
|
||||
procedure FormDestroy(Sender: TObject);
|
||||
procedure HTMLGetImageX(Sender: TIpHtmlNode; const URL: string;
|
||||
var Picture: TPicture);
|
||||
procedure IpHtmlPanel1HotClick(Sender: TObject);
|
||||
procedure SB_GoBackwardClick(Sender: TObject);
|
||||
procedure SB_GoForwardClick(Sender: TObject);
|
||||
private
|
||||
SL: TStringList;
|
||||
CurrPos: Integer;
|
||||
CurrFile: string;
|
||||
Path: string;
|
||||
PathChanged: Boolean;
|
||||
procedure GoBackFor (GoBack: Boolean);
|
||||
procedure OpenHTMLFile(const Filename: string;
|
||||
ToAdd, RelativePath: Boolean);
|
||||
end;
|
||||
|
||||
var
|
||||
FHtmFileExp1: TFHtmFileExp1;
|
||||
|
||||
implementation
|
||||
|
||||
uses
|
||||
IpUtils;
|
||||
|
||||
{--------------------------------------}
|
||||
{-EVENTS-----------}
|
||||
|
||||
procedure TFHtmFileExp1.FormCreate(Sender: TObject);
|
||||
begin
|
||||
SL := TStringList.Create;
|
||||
CurrPos := -1;
|
||||
OpenHTMLFile ('index.html', True, False);
|
||||
end;
|
||||
|
||||
procedure TFHtmFileExp1.FormDestroy(Sender: TObject);
|
||||
var
|
||||
I: Integer;
|
||||
begin
|
||||
for I := SL.Count-1 downto 0 do
|
||||
TPst(SL.Objects[I]).Free;
|
||||
SL.Free;
|
||||
end;
|
||||
|
||||
procedure TFHtmFileExp1.B_OpenHTMLFileClick(Sender: TObject);
|
||||
begin
|
||||
if OpenDialog1.Execute then begin
|
||||
OpenHtmlFile (OpenDialog1.FileName, True, False);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TFHtmFileExp1.HTMLGetImageX(Sender: TIpHtmlNode; const URL: string;
|
||||
var Picture: TPicture);
|
||||
var
|
||||
PicCreated: Boolean;
|
||||
FN, nURL: string;
|
||||
{$IFNDEF IP_LAZARUS}
|
||||
Ext: string;
|
||||
BitMap: Graphics.TBitMap;
|
||||
{$ENDIF}
|
||||
begin
|
||||
PicCreated := False;
|
||||
try
|
||||
if PathChanged
|
||||
then FN := Path
|
||||
else FN := ExtractFilePath(SL[CurrPos]);
|
||||
if Pos ('\',FN) <> 0
|
||||
then nURL := NetToDOSPath(URL)
|
||||
else nURL := URL;
|
||||
FN := Concat (FN, nURL);
|
||||
if FileExists(FN) then begin
|
||||
if Picture = nil then begin
|
||||
Picture := TPicture.Create;
|
||||
PicCreated := True;
|
||||
end;
|
||||
{$IFNDEF IP_LAZARUS}
|
||||
Ext := LowerCase (Copy (ExtractFileExt (FN), 2, MaxInt));
|
||||
if (Ext = 'bmp') or (Ext = 'emf') or (Ext = 'wmf') or (Ext = 'gif') or (Ext = 'jpg') then begin
|
||||
{$ENDIF}
|
||||
Picture.LoadFromFile(FN);
|
||||
{$IFNDEF IP_LAZARUS}
|
||||
end
|
||||
else begin
|
||||
PicCreated := False;
|
||||
BitMap := Graphics.TBitMap.Create;
|
||||
with TLinearBitmap.Create do
|
||||
try
|
||||
LoadFromFile (FN);
|
||||
AssignTo (Bitmap);
|
||||
Picture.Bitmap.Assign (BitMap);
|
||||
PicCreated := True;
|
||||
finally
|
||||
Bitmap.Free;
|
||||
Free;
|
||||
end;
|
||||
end;
|
||||
{$ENDIF}
|
||||
end;
|
||||
except
|
||||
if PicCreated then
|
||||
Picture.Free;
|
||||
Picture := nil;
|
||||
end;
|
||||
end {HTMLGetImageX};
|
||||
|
||||
procedure TFHtmFileExp1.IpHtmlPanel1HotClick(Sender: TObject);
|
||||
begin
|
||||
if IpHtmlPanel1.HotNode is TIpHtmlNodeA then begin
|
||||
TPst(SL.Objects[CurrPos]).Position := IpHtmlPanel1.VScrollPos;
|
||||
OpenHTMLFile (TIpHtmlNodeA(IpHtmlPanel1.HotNode).HRef, True, True);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TFHtmFileExp1.SB_GoBackwardClick(Sender: TObject);
|
||||
begin
|
||||
TPst(SL.Objects[CurrPos]).Position := IpHtmlPanel1.VScrollPos;
|
||||
GoBackFor (True);
|
||||
end;
|
||||
|
||||
procedure TFHtmFileExp1.SB_GoForwardClick(Sender: TObject);
|
||||
begin
|
||||
GoBackFor (False);
|
||||
end;
|
||||
|
||||
{-PRIVATE----------}
|
||||
|
||||
procedure TFHtmFileExp1.GoBackFor (GoBack: Boolean);
|
||||
var
|
||||
Pst: TPst;
|
||||
S: string;
|
||||
SameFile: Boolean;
|
||||
begin
|
||||
if GoBack
|
||||
then Dec (CurrPos)
|
||||
else Inc (CurrPos);
|
||||
if GoBack then begin
|
||||
SameFile := SL[CurrPos+1] = SL[CurrPos]
|
||||
end
|
||||
else begin
|
||||
if CurrPos > 0
|
||||
then SameFile := SL[CurrPos-1] = SL[CurrPos]
|
||||
else SameFile := False;
|
||||
end;
|
||||
if SameFile
|
||||
then S := ''
|
||||
else S := SL[CurrPos];
|
||||
Pst := TPst(SL.Objects[CurrPos]);
|
||||
OpenHTMLFile (S, False, True);
|
||||
IpHtmlPanel1.VScrollPos := Pst.Position;
|
||||
SB_GoBackward.Enabled := (SL.Count > 1) and (CurrPos > 0);
|
||||
SB_GoForward.Enabled := (SL.Count > 1) and (CurrPos < SL.Count-1);
|
||||
end {GoBackFor};
|
||||
|
||||
procedure TFHtmFileExp1.OpenHTMLFile(const Filename: string;
|
||||
ToAdd, RelativePath: Boolean);
|
||||
|
||||
var
|
||||
FN, Anchor: string;
|
||||
Pst: TPst;
|
||||
procedure UpdateSB;
|
||||
var
|
||||
I: Integer;
|
||||
begin
|
||||
if ToAdd then begin
|
||||
Pst := TPst.Create;
|
||||
Pst.Position := IpHtmlPanel1.VScrollPos;
|
||||
for I := SL.Count-1 downto CurrPos+1 do begin
|
||||
TPst(SL.Objects[I]).Free;
|
||||
SL.Delete(I);
|
||||
end;
|
||||
CurrPos := SL.AddObject (FN, Pst);
|
||||
SB_GoBackward.Enabled := SL.Count > 1;
|
||||
SB_GoForward.Enabled := False;
|
||||
end;
|
||||
end {UpdateSB};
|
||||
|
||||
var
|
||||
fs: TFileStream;
|
||||
NewHTML: TSimpleIpHtml;
|
||||
P: Integer;
|
||||
begin
|
||||
if Filename = '' then begin
|
||||
if CurrPos > -1
|
||||
then IpHtmlPanel1.VScrollPos := 0;
|
||||
Exit;
|
||||
end;
|
||||
P := Pos ('#', Filename);
|
||||
FN := Filename;
|
||||
if RelativePath then begin
|
||||
PathChanged := False;
|
||||
if P = 0 then begin
|
||||
Anchor := '';
|
||||
end
|
||||
else if P = 1 then begin
|
||||
FN := Concat (Path, CurrFile);
|
||||
Anchor := Copy (Filename, 2, MaxInt);
|
||||
IpHtmlPanel1.MakeAnchorVisible (Anchor);
|
||||
UpdateSB;
|
||||
Exit;
|
||||
end
|
||||
else begin
|
||||
FN := Copy (Filename, 1, P-1);
|
||||
Anchor := Copy (Filename, P+1, MaxInt);
|
||||
end;
|
||||
if ToAdd then begin
|
||||
FN := Concat (Path, FN);
|
||||
end;
|
||||
end
|
||||
else begin
|
||||
FN := ExpandFileName(FN);
|
||||
CurrFile := ExtractFileName (FN);
|
||||
Path := ExtractFilePath (FN);
|
||||
PathChanged := True;
|
||||
end;
|
||||
try
|
||||
fs := TFileStream.Create (FN, fmOpenRead);
|
||||
try
|
||||
NewHTML := TSimpleIpHtml.Create; // Beware: Will be freed automatically by IpHtmlPanel1
|
||||
NewHTML.OnGetImageX := @HTMLGetImageX;
|
||||
NewHTML.LoadFromStream (fs);
|
||||
IpHtmlPanel1.SetHtml (NewHTML);
|
||||
if Anchor <> ''
|
||||
then IpHtmlPanel1.MakeAnchorVisible (Anchor);
|
||||
UpdateSB;
|
||||
finally
|
||||
fs.Free;
|
||||
end;
|
||||
except
|
||||
on E: Exception do begin
|
||||
MessageDlg ('Unable to open HTML file'+sLineBreak+
|
||||
'HTML File: '+Filename+sLineBreak+
|
||||
'Error: '+E.Message, mtError, [mbCancel], 0);
|
||||
end;
|
||||
end;
|
||||
end {OpenHTMLFile};
|
||||
|
||||
{--------------------------------------}
|
||||
|
||||
initialization
|
||||
{$I htmfileexp1.lrs}
|
||||
{$I defaultimage.lrs}
|
||||
|
||||
end.
|
||||
|
||||
158
components/turbopower_ipro/examples/htmfileexp2.lfm
Normal file
158
components/turbopower_ipro/examples/htmfileexp2.lfm
Normal file
@ -0,0 +1,158 @@
|
||||
object FHtmFileExp2: TFHtmFileExp2
|
||||
Left = 454
|
||||
Height = 327
|
||||
Top = 373
|
||||
Width = 569
|
||||
HorzScrollBar.Page = 568
|
||||
VertScrollBar.Page = 326
|
||||
ActiveControl = B_OpenHTMLFile
|
||||
Caption = 'Example 2 for turbopower: HTM File Explorer'
|
||||
OnCreate = FormCreate
|
||||
object P_Top: TPanel
|
||||
Height = 42
|
||||
Width = 569
|
||||
Align = alTop
|
||||
TabOrder = 0
|
||||
object SB_GoBackward: TSpeedButton
|
||||
Left = 176
|
||||
Height = 25
|
||||
Top = 8
|
||||
Width = 25
|
||||
Color = clBtnFace
|
||||
Enabled = False
|
||||
Glyph.Data = {
|
||||
36060000424D3606000000000000360400002800000020000000100000000100
|
||||
0800000000000002000000000000000000000000000000000000000000000000
|
||||
80000080000000808000800000008000800080800000C0C0C000C0DCC000F0CA
|
||||
A6000020400000206000002080000020A0000020C0000020E000004000000040
|
||||
20000040400000406000004080000040A0000040C0000040E000006000000060
|
||||
20000060400000606000006080000060A0000060C0000060E000008000000080
|
||||
20000080400000806000008080000080A0000080C0000080E00000A0000000A0
|
||||
200000A0400000A0600000A0800000A0A00000A0C00000A0E00000C0000000C0
|
||||
200000C0400000C0600000C0800000C0A00000C0C00000C0E00000E0000000E0
|
||||
200000E0400000E0600000E0800000E0A00000E0C00000E0E000400000004000
|
||||
20004000400040006000400080004000A0004000C0004000E000402000004020
|
||||
20004020400040206000402080004020A0004020C0004020E000404000004040
|
||||
20004040400040406000404080004040A0004040C0004040E000406000004060
|
||||
20004060400040606000406080004060A0004060C0004060E000408000004080
|
||||
20004080400040806000408080004080A0004080C0004080E00040A0000040A0
|
||||
200040A0400040A0600040A0800040A0A00040A0C00040A0E00040C0000040C0
|
||||
200040C0400040C0600040C0800040C0A00040C0C00040C0E00040E0000040E0
|
||||
200040E0400040E0600040E0800040E0A00040E0C00040E0E000800000008000
|
||||
20008000400080006000800080008000A0008000C0008000E000802000008020
|
||||
20008020400080206000802080008020A0008020C0008020E000804000008040
|
||||
20008040400080406000804080008040A0008040C0008040E000806000008060
|
||||
20008060400080606000806080008060A0008060C0008060E000808000008080
|
||||
20008080400080806000808080008080A0008080C0008080E00080A0000080A0
|
||||
200080A0400080A0600080A0800080A0A00080A0C00080A0E00080C0000080C0
|
||||
200080C0400080C0600080C0800080C0A00080C0C00080C0E00080E0000080E0
|
||||
200080E0400080E0600080E0800080E0A00080E0C00080E0E000C0000000C000
|
||||
2000C0004000C0006000C0008000C000A000C000C000C000E000C0200000C020
|
||||
2000C0204000C0206000C0208000C020A000C020C000C020E000C0400000C040
|
||||
2000C0404000C0406000C0408000C040A000C040C000C040E000C0600000C060
|
||||
2000C0604000C0606000C0608000C060A000C060C000C060E000C0800000C080
|
||||
2000C0804000C0806000C0808000C080A000C080C000C080E000C0A00000C0A0
|
||||
2000C0A04000C0A06000C0A08000C0A0A000C0A0C000C0A0E000C0C00000C0C0
|
||||
2000C0C04000C0C06000C0C08000C0C0A000F0FBFF00A4A0A000808080000000
|
||||
FF0000FF000000FFFF00FF000000FF00FF00FFFF0000FFFFFF00FDFDFDFDFDFD
|
||||
FDF5F5FDFDFDFDFDFDFDFDFDFDFDFDFDFD0707FDFDFDFDFDFDFDFDFDFDFDFDFD
|
||||
B51111FDFDFDFDFDFDFDFDFDFDFDFDFD07F7F7FDFDFDFDFDFDFDFDFDFDFDFDB5
|
||||
196219FDFDFDFDFDFDFDFDFDFDFDFD07F707F7FDFDFDFDFDFDFDFDFDFDFDAC11
|
||||
627362FDFDFDFDFDFDFDFDFDFDFD07F7070707FDFDFDFDFDFDFDFDFDFDAC1962
|
||||
737361B4B4F7ACADF7FDFDFDFD07F707070707070707070707FDFDFDAC1162B3
|
||||
696A61181919191951FDFDFD07F70707070707F7F7F7F7F7F7FDFDAC1162BCB3
|
||||
69697272737373B462FDFD07F7070707F707070707070707F7FDB41162B3B3B3
|
||||
B2686969727272B462FD07F7070707070707070707070707F7FD616AF4B3B3B3
|
||||
BB696869696969B361FDF7070707070707F7070707070707F7FDFD61AABBB3B4
|
||||
BCBB6968696969BB61FDFDF7070707070707F7F7F7F7F707F7FDFDFD61AABCBC
|
||||
B4F4BCBCBCBCBCBC61FDFDFDF70707070707070707070707F7FDFDFDFD61AAF4
|
||||
B4F561616162616262FDFDFDFDF707070707F7F7F7F7F7F7F7FDFDFDFDFD61AA
|
||||
BCF561FDFDFDFDFDFDFDFDFDFDFDF7070707F7FDFDFDFDFDFDFDFDFDFDFDFD61
|
||||
AAF462FDFDFDFDFDFDFDFDFDFDFDFDF70707F7FDFDFDFDFDFDFDFDFDFDFDFDFD
|
||||
61AA61FDFDFDFDFDFDFDFDFDFDFDFDFDF707F7FDFDFDFDFDFDFDFDFDFDFDFDFD
|
||||
FD6161FDFDFDFDFDFDFDFDFDFDFDFDFDFDF7F7FDFDFDFDFDFDFD
|
||||
}
|
||||
NumGlyphs = 2
|
||||
OnClick = SB_GoBackwardClick
|
||||
end
|
||||
object SB_GoForward: TSpeedButton
|
||||
Left = 208
|
||||
Height = 25
|
||||
Top = 8
|
||||
Width = 25
|
||||
Color = clBtnFace
|
||||
Enabled = False
|
||||
Glyph.Data = {
|
||||
36060000424D3606000000000000360400002800000020000000100000000100
|
||||
0800000000000002000000000000000000000000000000000000000000000000
|
||||
80000080000000808000800000008000800080800000C0C0C000C0DCC000F0CA
|
||||
A6000020400000206000002080000020A0000020C0000020E000004000000040
|
||||
20000040400000406000004080000040A0000040C0000040E000006000000060
|
||||
20000060400000606000006080000060A0000060C0000060E000008000000080
|
||||
20000080400000806000008080000080A0000080C0000080E00000A0000000A0
|
||||
200000A0400000A0600000A0800000A0A00000A0C00000A0E00000C0000000C0
|
||||
200000C0400000C0600000C0800000C0A00000C0C00000C0E00000E0000000E0
|
||||
200000E0400000E0600000E0800000E0A00000E0C00000E0E000400000004000
|
||||
20004000400040006000400080004000A0004000C0004000E000402000004020
|
||||
20004020400040206000402080004020A0004020C0004020E000404000004040
|
||||
20004040400040406000404080004040A0004040C0004040E000406000004060
|
||||
20004060400040606000406080004060A0004060C0004060E000408000004080
|
||||
20004080400040806000408080004080A0004080C0004080E00040A0000040A0
|
||||
200040A0400040A0600040A0800040A0A00040A0C00040A0E00040C0000040C0
|
||||
200040C0400040C0600040C0800040C0A00040C0C00040C0E00040E0000040E0
|
||||
200040E0400040E0600040E0800040E0A00040E0C00040E0E000800000008000
|
||||
20008000400080006000800080008000A0008000C0008000E000802000008020
|
||||
20008020400080206000802080008020A0008020C0008020E000804000008040
|
||||
20008040400080406000804080008040A0008040C0008040E000806000008060
|
||||
20008060400080606000806080008060A0008060C0008060E000808000008080
|
||||
20008080400080806000808080008080A0008080C0008080E00080A0000080A0
|
||||
200080A0400080A0600080A0800080A0A00080A0C00080A0E00080C0000080C0
|
||||
200080C0400080C0600080C0800080C0A00080C0C00080C0E00080E0000080E0
|
||||
200080E0400080E0600080E0800080E0A00080E0C00080E0E000C0000000C000
|
||||
2000C0004000C0006000C0008000C000A000C000C000C000E000C0200000C020
|
||||
2000C0204000C0206000C0208000C020A000C020C000C020E000C0400000C040
|
||||
2000C0404000C0406000C0408000C040A000C040C000C040E000C0600000C060
|
||||
2000C0604000C0606000C0608000C060A000C060C000C060E000C0800000C080
|
||||
2000C0804000C0806000C0808000C080A000C080C000C080E000C0A00000C0A0
|
||||
2000C0A04000C0A06000C0A08000C0A0A000C0A0C000C0A0E000C0C00000C0C0
|
||||
2000C0C04000C0C06000C0C08000C0C0A000F0FBFF00A4A0A000808080000000
|
||||
FF0000FF000000FFFF00FF000000FF00FF00FFFF0000FFFFFF00FDFDFDFDFDFD
|
||||
FDF5F5FDFDFDFDFDFDFDFDFDFDFDFDFDFD0707FDFDFDFDFDFDFDFDFDFDFDFDFD
|
||||
FD1111B5FDFDFDFDFDFDFDFDFDFDFDFDFDF7F707FDFDFDFDFDFDFDFDFDFDFDFD
|
||||
FD196219B5FDFDFDFDFDFDFDFDFDFDFDFDF707F707FDFDFDFDFDFDFDFDFDFDFD
|
||||
FD62736211ACFDFDFDFDFDFDFDFDFDFDFD070707F707FDFDFDFDFDF7ADACF7B4
|
||||
B46173736219ACFDFDFDFD07070707070707070707F707FDFDFDFD5119191919
|
||||
18616A69B36211ACFDFDFDF7F7F7F7F7F70707070707F707FDFDFD62B4737373
|
||||
72726969B3BC6211ACFDFDF707070707070707F7070707F707FDFD62B4727272
|
||||
696968B2B3B3B36211B4FDF7070707070707070707070707F707FD61B3696969
|
||||
696869BBB3B3B3F46A61FDF707070707070707070707070707F7FD61BB696969
|
||||
6869BBBCB4B3BBAA61FDFDF70707F707F7F7070707070707F7FDFD61BCBCBCBC
|
||||
BCBCF4B4BCBCAA61FDFDFDF70707070707070707070707F7FDFDFD6262616261
|
||||
6161F5B4F4AA61FDFDFDFDF7F707F7F707F707070707F7FDFDFDFDFDFDFDFDFD
|
||||
FD61F5BCAA61FDFDFDFDFDFDFDFDFDFDFDF7070707F7FDFDFDFDFDFDFDFDFDFD
|
||||
FD62F4AA61FDFDFDFDFDFDFDFDFDFDFDFDF70707F7FDFDFDFDFDFDFDFDFDFDFD
|
||||
FD61AA61FDFDFDFDFDFDFDFDFDFDFDFDFDF707F7FDFDFDFDFDFDFDFDFDFDFDFD
|
||||
FD6161FDFDFDFDFDFDFDFDFDFDFDFDFDFDF7F7FDFDFDFDFDFDFD
|
||||
}
|
||||
NumGlyphs = 2
|
||||
OnClick = SB_GoForwardClick
|
||||
end
|
||||
object B_OpenHTMLFile: TButton
|
||||
Left = 16
|
||||
Height = 26
|
||||
Top = 8
|
||||
Width = 152
|
||||
BorderSpacing.InnerBorder = 4
|
||||
Caption = 'Open HTML File'
|
||||
OnClick = B_OpenHTMLFileClick
|
||||
TabOrder = 0
|
||||
end
|
||||
end
|
||||
object OpenDialog1: TOpenDialog
|
||||
Title = 'Open existing file'
|
||||
Filter = 'Web Pages|*.html;*.htm'
|
||||
FilterIndex = 0
|
||||
left = 26
|
||||
top = 93
|
||||
end
|
||||
end
|
||||
147
components/turbopower_ipro/examples/htmfileexp2.lrs
Normal file
147
components/turbopower_ipro/examples/htmfileexp2.lrs
Normal file
@ -0,0 +1,147 @@
|
||||
{ Das ist eine automatisch erzeugte Lazarus-Ressourcendatei }
|
||||
|
||||
LazarusResources.Add('TFHtmFileExp2','FORMDATA',[
|
||||
'TPF0'#13'TFHtmFileExp2'#12'FHtmFileExp2'#4'Left'#3#198#1#6'Height'#3'G'#1#3
|
||||
+'Top'#3'u'#1#5'Width'#3'9'#2#18'HorzScrollBar.Page'#3'8'#2#18'VertScrollBar.'
|
||||
+'Page'#3'F'#1#13'ActiveControl'#7#14'B_OpenHTMLFile'#7'Caption'#6'+Example 2'
|
||||
+' for turbopower: HTM File Explorer'#8'OnCreate'#7#10'FormCreate'#0#6'TPanel'
|
||||
+#5'P_Top'#6'Height'#2'*'#5'Width'#3'9'#2#5'Align'#7#5'alTop'#8'TabOrder'#2#0
|
||||
+#0#12'TSpeedButton'#13'SB_GoBackward'#4'Left'#3#176#0#6'Height'#2#25#3'Top'#2
|
||||
+#8#5'Width'#2#25#5'Color'#7#9'clBtnFace'#7'Enabled'#8#10'Glyph.Data'#10':'#6
|
||||
+#0#0'6'#6#0#0'BM6'#6#0#0#0#0#0#0'6'#4#0#0'('#0#0#0' '#0#0#0#16#0#0#0#1#0#8#0
|
||||
+#0#0#0#0#0#2#0#0#0#0#0#0#0#0#0#0#0#0#0#0#0#0#0#0#0#0#0#0#0#0#128#0#0#128#0#0
|
||||
+#0#128#128#0#128#0#0#0#128#0#128#0#128#128#0#0#192#192#192#0#192#220#192#0
|
||||
+#240#202#166#0#0' @'#0#0' `'#0#0' '#128#0#0' '#160#0#0' '#192#0#0' '#224#0#0
|
||||
+'@'#0#0#0'@ '#0#0'@@'#0#0'@`'#0#0'@'#128#0#0'@'#160#0#0'@'#192#0#0'@'#224#0#0
|
||||
+'`'#0#0#0'` '#0#0'`@'#0#0'``'#0#0'`'#128#0#0'`'#160#0#0'`'#192#0#0'`'#224#0#0
|
||||
+#128#0#0#0#128' '#0#0#128'@'#0#0#128'`'#0#0#128#128#0#0#128#160#0#0#128#192#0
|
||||
+#0#128#224#0#0#160#0#0#0#160' '#0#0#160'@'#0#0#160'`'#0#0#160#128#0#0#160#160
|
||||
+#0#0#160#192#0#0#160#224#0#0#192#0#0#0#192' '#0#0#192'@'#0#0#192'`'#0#0#192
|
||||
+#128#0#0#192#160#0#0#192#192#0#0#192#224#0#0#224#0#0#0#224' '#0#0#224'@'#0#0
|
||||
+#224'`'#0#0#224#128#0#0#224#160#0#0#224#192#0#0#224#224#0'@'#0#0#0'@'#0' '#0
|
||||
+'@'#0'@'#0'@'#0'`'#0'@'#0#128#0'@'#0#160#0'@'#0#192#0'@'#0#224#0'@ '#0#0'@ '
|
||||
+#0'@ @'#0'@ `'#0'@ '#128#0'@ '#160#0'@ '#192#0'@ '#224#0'@@'#0#0'@@ '#0'@@@'
|
||||
+#0'@@`'#0'@@'#128#0'@@'#160#0'@@'#192#0'@@'#224#0'@`'#0#0'@` '#0'@`@'#0'@``'
|
||||
+#0'@`'#128#0'@`'#160#0'@`'#192#0'@`'#224#0'@'#128#0#0'@'#128' '#0'@'#128'@'#0
|
||||
+'@'#128'`'#0'@'#128#128#0'@'#128#160#0'@'#128#192#0'@'#128#224#0'@'#160#0#0
|
||||
+'@'#160' '#0'@'#160'@'#0'@'#160'`'#0'@'#160#128#0'@'#160#160#0'@'#160#192#0
|
||||
+'@'#160#224#0'@'#192#0#0'@'#192' '#0'@'#192'@'#0'@'#192'`'#0'@'#192#128#0'@'
|
||||
+#192#160#0'@'#192#192#0'@'#192#224#0'@'#224#0#0'@'#224' '#0'@'#224'@'#0'@'
|
||||
+#224'`'#0'@'#224#128#0'@'#224#160#0'@'#224#192#0'@'#224#224#0#128#0#0#0#128#0
|
||||
+' '#0#128#0'@'#0#128#0'`'#0#128#0#128#0#128#0#160#0#128#0#192#0#128#0#224#0
|
||||
+#128' '#0#0#128' '#0#128' @'#0#128' `'#0#128' '#128#0#128' '#160#0#128' '
|
||||
+#192#0#128' '#224#0#128'@'#0#0#128'@ '#0#128'@@'#0#128'@`'#0#128'@'#128#0#128
|
||||
+'@'#160#0#128'@'#192#0#128'@'#224#0#128'`'#0#0#128'` '#0#128'`@'#0#128'``'#0
|
||||
+#128'`'#128#0#128'`'#160#0#128'`'#192#0#128'`'#224#0#128#128#0#0#128#128' '#0
|
||||
+#128#128'@'#0#128#128'`'#0#128#128#128#0#128#128#160#0#128#128#192#0#128#128
|
||||
+#224#0#128#160#0#0#128#160' '#0#128#160'@'#0#128#160'`'#0#128#160#128#0#128
|
||||
+#160#160#0#128#160#192#0#128#160#224#0#128#192#0#0#128#192' '#0#128#192'@'#0
|
||||
+#128#192'`'#0#128#192#128#0#128#192#160#0#128#192#192#0#128#192#224#0#128#224
|
||||
+#0#0#128#224' '#0#128#224'@'#0#128#224'`'#0#128#224#128#0#128#224#160#0#128
|
||||
+#224#192#0#128#224#224#0#192#0#0#0#192#0' '#0#192#0'@'#0#192#0'`'#0#192#0#128
|
||||
+#0#192#0#160#0#192#0#192#0#192#0#224#0#192' '#0#0#192' '#0#192' @'#0#192' `'
|
||||
+#0#192' '#128#0#192' '#160#0#192' '#192#0#192' '#224#0#192'@'#0#0#192'@ '#0
|
||||
+#192'@@'#0#192'@`'#0#192'@'#128#0#192'@'#160#0#192'@'#192#0#192'@'#224#0#192
|
||||
+'`'#0#0#192'` '#0#192'`@'#0#192'``'#0#192'`'#128#0#192'`'#160#0#192'`'#192#0
|
||||
+#192'`'#224#0#192#128#0#0#192#128' '#0#192#128'@'#0#192#128'`'#0#192#128#128
|
||||
+#0#192#128#160#0#192#128#192#0#192#128#224#0#192#160#0#0#192#160' '#0#192#160
|
||||
+'@'#0#192#160'`'#0#192#160#128#0#192#160#160#0#192#160#192#0#192#160#224#0
|
||||
+#192#192#0#0#192#192' '#0#192#192'@'#0#192#192'`'#0#192#192#128#0#192#192#160
|
||||
+#0#240#251#255#0#164#160#160#0#128#128#128#0#0#0#255#0#0#255#0#0#0#255#255#0
|
||||
+#255#0#0#0#255#0#255#0#255#255#0#0#255#255#255#0#253#253#253#253#253#253#253
|
||||
+#245#245#253#253#253#253#253#253#253#253#253#253#253#253#253#253#7#7#253#253
|
||||
+#253#253#253#253#253#253#253#253#253#253#253#181#17#17#253#253#253#253#253
|
||||
+#253#253#253#253#253#253#253#253#7#247#247#253#253#253#253#253#253#253#253
|
||||
+#253#253#253#253#181#25'b'#25#253#253#253#253#253#253#253#253#253#253#253#253
|
||||
+#7#247#7#247#253#253#253#253#253#253#253#253#253#253#253#172#17'bsb'#253#253
|
||||
+#253#253#253#253#253#253#253#253#253#7#247#7#7#7#253#253#253#253#253#253#253
|
||||
+#253#253#253#172#25'bssa'#180#180#247#172#173#247#253#253#253#253#7#247#7#7#7
|
||||
+#7#7#7#7#7#7#7#253#253#253#172#17'b'#179'ija'#24#25#25#25#25'Q'#253#253#253#7
|
||||
+#247#7#7#7#7#7#247#247#247#247#247#247#253#253#172#17'b'#188#179'iirrsss'#180
|
||||
+'b'#253#253#7#247#7#7#7#247#7#7#7#7#7#7#7#247#253#180#17'b'#179#179#179#178
|
||||
+'hiirrr'#180'b'#253#7#247#7#7#7#7#7#7#7#7#7#7#7#7#247#253'aj'#244#179#179#179
|
||||
+#187'ihiiii'#179'a'#253#247#7#7#7#7#7#7#247#7#7#7#7#7#7#247#253#253'a'#170
|
||||
+#187#179#180#188#187'ihiii'#187'a'#253#253#247#7#7#7#7#7#7#247#247#247#247
|
||||
+#247#7#247#253#253#253'a'#170#188#188#180#244#188#188#188#188#188#188'a'#253
|
||||
+#253#253#247#7#7#7#7#7#7#7#7#7#7#7#247#253#253#253#253'a'#170#244#180#245'aa'
|
||||
+'ababb'#253#253#253#253#247#7#7#7#7#247#247#247#247#247#247#247#253#253#253
|
||||
,#253#253'a'#170#188#245'a'#253#253#253#253#253#253#253#253#253#253#253#247#7
|
||||
+#7#7#247#253#253#253#253#253#253#253#253#253#253#253#253'a'#170#244'b'#253
|
||||
+#253#253#253#253#253#253#253#253#253#253#253#247#7#7#247#253#253#253#253#253
|
||||
+#253#253#253#253#253#253#253#253'a'#170'a'#253#253#253#253#253#253#253#253
|
||||
+#253#253#253#253#253#247#7#247#253#253#253#253#253#253#253#253#253#253#253
|
||||
+#253#253#253'aa'#253#253#253#253#253#253#253#253#253#253#253#253#253#253#247
|
||||
+#247#253#253#253#253#253#253#253#9'NumGlyphs'#2#2#7'OnClick'#7#18'SB_GoBackw'
|
||||
+'ardClick'#0#0#12'TSpeedButton'#12'SB_GoForward'#4'Left'#3#208#0#6'Height'#2
|
||||
+#25#3'Top'#2#8#5'Width'#2#25#5'Color'#7#9'clBtnFace'#7'Enabled'#8#10'Glyph.D'
|
||||
+'ata'#10':'#6#0#0'6'#6#0#0'BM6'#6#0#0#0#0#0#0'6'#4#0#0'('#0#0#0' '#0#0#0#16#0
|
||||
+#0#0#1#0#8#0#0#0#0#0#0#2#0#0#0#0#0#0#0#0#0#0#0#0#0#0#0#0#0#0#0#0#0#0#0#0#128
|
||||
+#0#0#128#0#0#0#128#128#0#128#0#0#0#128#0#128#0#128#128#0#0#192#192#192#0#192
|
||||
+#220#192#0#240#202#166#0#0' @'#0#0' `'#0#0' '#128#0#0' '#160#0#0' '#192#0#0
|
||||
+' '#224#0#0'@'#0#0#0'@ '#0#0'@@'#0#0'@`'#0#0'@'#128#0#0'@'#160#0#0'@'#192#0#0
|
||||
+'@'#224#0#0'`'#0#0#0'` '#0#0'`@'#0#0'``'#0#0'`'#128#0#0'`'#160#0#0'`'#192#0#0
|
||||
+'`'#224#0#0#128#0#0#0#128' '#0#0#128'@'#0#0#128'`'#0#0#128#128#0#0#128#160#0
|
||||
+#0#128#192#0#0#128#224#0#0#160#0#0#0#160' '#0#0#160'@'#0#0#160'`'#0#0#160#128
|
||||
+#0#0#160#160#0#0#160#192#0#0#160#224#0#0#192#0#0#0#192' '#0#0#192'@'#0#0#192
|
||||
+'`'#0#0#192#128#0#0#192#160#0#0#192#192#0#0#192#224#0#0#224#0#0#0#224' '#0#0
|
||||
+#224'@'#0#0#224'`'#0#0#224#128#0#0#224#160#0#0#224#192#0#0#224#224#0'@'#0#0#0
|
||||
+'@'#0' '#0'@'#0'@'#0'@'#0'`'#0'@'#0#128#0'@'#0#160#0'@'#0#192#0'@'#0#224#0'@'
|
||||
+' '#0#0'@ '#0'@ @'#0'@ `'#0'@ '#128#0'@ '#160#0'@ '#192#0'@ '#224#0'@@'#0#0
|
||||
+'@@ '#0'@@@'#0'@@`'#0'@@'#128#0'@@'#160#0'@@'#192#0'@@'#224#0'@`'#0#0'@` '#0
|
||||
+'@`@'#0'@``'#0'@`'#128#0'@`'#160#0'@`'#192#0'@`'#224#0'@'#128#0#0'@'#128' '#0
|
||||
+'@'#128'@'#0'@'#128'`'#0'@'#128#128#0'@'#128#160#0'@'#128#192#0'@'#128#224#0
|
||||
+'@'#160#0#0'@'#160' '#0'@'#160'@'#0'@'#160'`'#0'@'#160#128#0'@'#160#160#0'@'
|
||||
+#160#192#0'@'#160#224#0'@'#192#0#0'@'#192' '#0'@'#192'@'#0'@'#192'`'#0'@'#192
|
||||
+#128#0'@'#192#160#0'@'#192#192#0'@'#192#224#0'@'#224#0#0'@'#224' '#0'@'#224
|
||||
+'@'#0'@'#224'`'#0'@'#224#128#0'@'#224#160#0'@'#224#192#0'@'#224#224#0#128#0#0
|
||||
+#0#128#0' '#0#128#0'@'#0#128#0'`'#0#128#0#128#0#128#0#160#0#128#0#192#0#128#0
|
||||
+#224#0#128' '#0#0#128' '#0#128' @'#0#128' `'#0#128' '#128#0#128' '#160#0#128
|
||||
+' '#192#0#128' '#224#0#128'@'#0#0#128'@ '#0#128'@@'#0#128'@`'#0#128'@'#128#0
|
||||
+#128'@'#160#0#128'@'#192#0#128'@'#224#0#128'`'#0#0#128'` '#0#128'`@'#0#128'`'
|
||||
+'`'#0#128'`'#128#0#128'`'#160#0#128'`'#192#0#128'`'#224#0#128#128#0#0#128#128
|
||||
+' '#0#128#128'@'#0#128#128'`'#0#128#128#128#0#128#128#160#0#128#128#192#0#128
|
||||
+#128#224#0#128#160#0#0#128#160' '#0#128#160'@'#0#128#160'`'#0#128#160#128#0
|
||||
+#128#160#160#0#128#160#192#0#128#160#224#0#128#192#0#0#128#192' '#0#128#192
|
||||
+'@'#0#128#192'`'#0#128#192#128#0#128#192#160#0#128#192#192#0#128#192#224#0
|
||||
+#128#224#0#0#128#224' '#0#128#224'@'#0#128#224'`'#0#128#224#128#0#128#224#160
|
||||
+#0#128#224#192#0#128#224#224#0#192#0#0#0#192#0' '#0#192#0'@'#0#192#0'`'#0#192
|
||||
+#0#128#0#192#0#160#0#192#0#192#0#192#0#224#0#192' '#0#0#192' '#0#192' @'#0
|
||||
+#192' `'#0#192' '#128#0#192' '#160#0#192' '#192#0#192' '#224#0#192'@'#0#0#192
|
||||
+'@ '#0#192'@@'#0#192'@`'#0#192'@'#128#0#192'@'#160#0#192'@'#192#0#192'@'#224
|
||||
+#0#192'`'#0#0#192'` '#0#192'`@'#0#192'``'#0#192'`'#128#0#192'`'#160#0#192'`'
|
||||
+#192#0#192'`'#224#0#192#128#0#0#192#128' '#0#192#128'@'#0#192#128'`'#0#192
|
||||
+#128#128#0#192#128#160#0#192#128#192#0#192#128#224#0#192#160#0#0#192#160' '#0
|
||||
+#192#160'@'#0#192#160'`'#0#192#160#128#0#192#160#160#0#192#160#192#0#192#160
|
||||
+#224#0#192#192#0#0#192#192' '#0#192#192'@'#0#192#192'`'#0#192#192#128#0#192
|
||||
+#192#160#0#240#251#255#0#164#160#160#0#128#128#128#0#0#0#255#0#0#255#0#0#0
|
||||
+#255#255#0#255#0#0#0#255#0#255#0#255#255#0#0#255#255#255#0#253#253#253#253
|
||||
+#253#253#253#245#245#253#253#253#253#253#253#253#253#253#253#253#253#253#253
|
||||
+#7#7#253#253#253#253#253#253#253#253#253#253#253#253#253#253#17#17#181#253
|
||||
+#253#253#253#253#253#253#253#253#253#253#253#253#247#247#7#253#253#253#253
|
||||
+#253#253#253#253#253#253#253#253#253#25'b'#25#181#253#253#253#253#253#253#253
|
||||
+#253#253#253#253#253#247#7#247#7#253#253#253#253#253#253#253#253#253#253#253
|
||||
+#253'bsb'#17#172#253#253#253#253#253#253#253#253#253#253#253#7#7#7#247#7#253
|
||||
+#253#253#253#253#247#173#172#247#180#180'assb'#25#172#253#253#253#253#7#7#7#7
|
||||
+#7#7#7#7#7#7#247#7#253#253#253#253'Q'#25#25#25#25#24'aji'#179'b'#17#172#253
|
||||
+#253#253#247#247#247#247#247#247#7#7#7#7#7#247#7#253#253#253'b'#180'sssrrii'
|
||||
+#179#188'b'#17#172#253#253#247#7#7#7#7#7#7#7#247#7#7#7#247#7#253#253'b'#180
|
||||
+'rrriih'#178#179#179#179'b'#17#180#253#247#7#7#7#7#7#7#7#7#7#7#7#7#247#7#253
|
||||
+'a'#179'iiiihi'#187#179#179#179#244'ja'#253#247#7#7#7#7#7#7#7#7#7#7#7#7#7#247
|
||||
+#253'a'#187'iiihi'#187#188#180#179#187#170'a'#253#253#247#7#7#247#7#247#247#7
|
||||
+#7#7#7#7#7#247#253#253'a'#188#188#188#188#188#188#244#180#188#188#170'a'#253
|
||||
,#253#253#247#7#7#7#7#7#7#7#7#7#7#7#247#253#253#253'bbabaaa'#245#180#244#170
|
||||
+'a'#253#253#253#253#247#247#7#247#247#7#247#7#7#7#7#247#253#253#253#253#253
|
||||
+#253#253#253#253#253'a'#245#188#170'a'#253#253#253#253#253#253#253#253#253
|
||||
+#253#253#247#7#7#7#247#253#253#253#253#253#253#253#253#253#253#253'b'#244#170
|
||||
+'a'#253#253#253#253#253#253#253#253#253#253#253#253#247#7#7#247#253#253#253
|
||||
+#253#253#253#253#253#253#253#253#253'a'#170'a'#253#253#253#253#253#253#253
|
||||
+#253#253#253#253#253#253#247#7#247#253#253#253#253#253#253#253#253#253#253
|
||||
+#253#253#253'aa'#253#253#253#253#253#253#253#253#253#253#253#253#253#253#247
|
||||
+#247#253#253#253#253#253#253#253#9'NumGlyphs'#2#2#7'OnClick'#7#17'SB_GoForwa'
|
||||
+'rdClick'#0#0#7'TButton'#14'B_OpenHTMLFile'#4'Left'#2#16#6'Height'#2#26#3'To'
|
||||
+'p'#2#8#5'Width'#3#152#0#25'BorderSpacing.InnerBorder'#2#4#7'Caption'#6#14'O'
|
||||
+'pen HTML File'#7'OnClick'#7#19'B_OpenHTMLFileClick'#8'TabOrder'#2#0#0#0#0#11
|
||||
+'TOpenDialog'#11'OpenDialog1'#5'Title'#6#18'Open existing file'#6'Filter'#6
|
||||
+#22'Web Pages|*.html;*.htm'#11'FilterIndex'#2#0#4'left'#2#26#3'top'#2']'#0#0
|
||||
+#0
|
||||
]);
|
||||
337
components/turbopower_ipro/examples/htmfileexp2.pas
Normal file
337
components/turbopower_ipro/examples/htmfileexp2.pas
Normal file
@ -0,0 +1,337 @@
|
||||
unit HtmFileExp2;
|
||||
|
||||
{$mode objfpc}{$H+}
|
||||
|
||||
{.$define UsePreview}
|
||||
{$define UseJPEG}
|
||||
{$IFDEF LCL}
|
||||
{$DEFINE IP_LAZARUS}
|
||||
{$ENDIF}
|
||||
|
||||
interface
|
||||
|
||||
uses
|
||||
Classes, SysUtils, LResources, Forms, Controls, Graphics, Dialogs, Buttons,
|
||||
{$IFDEF IP_LAZARUS}
|
||||
{$ifdef UseJPEG}
|
||||
LazJpeg,
|
||||
{$endif}
|
||||
{$ifdef UsePreview}
|
||||
OsPrinters,
|
||||
{$endif}
|
||||
{$ELSE}
|
||||
GIFImage,
|
||||
JPeg,
|
||||
ImageDLLLoader, PNGLoader, LinarBitmap, //from ImageFileLib of Michael Vinther: http://www.logicnet.dk/lib/
|
||||
{$ENDIF}
|
||||
IpHtml, ExtCtrls, StdCtrls;
|
||||
|
||||
type
|
||||
TSimpleIpHtml = class(TIpHtml)
|
||||
public
|
||||
property OnGetImageX;
|
||||
end;
|
||||
|
||||
TPst = class(TObject)
|
||||
Position: Integer;
|
||||
end;
|
||||
|
||||
TIpHtmlPanelH = class(TIpHtmlPanel)
|
||||
private
|
||||
SL: TStringList;
|
||||
CurrPos: Integer;
|
||||
CurrFile: string;
|
||||
Path: string;
|
||||
PathChanged: Boolean;
|
||||
FC_GoForward: TControl;
|
||||
FC_GoBackward: TControl;
|
||||
procedure GoBackFor (GotoBack: Boolean);
|
||||
procedure HTMLGetImageX(Sender: TIpHtmlNode; const URL: string;
|
||||
var Picture: TPicture);
|
||||
procedure HotClickH(Sender: TObject);
|
||||
public
|
||||
constructor Create(AOwner: TComponent); override;
|
||||
destructor Destroy; override;
|
||||
procedure GoBackward;
|
||||
procedure GoForward;
|
||||
procedure OpenHTMLFile(const Filename: string;
|
||||
ToAdd, RelativePath: Boolean);
|
||||
published
|
||||
property C_GoBackward: TControl read FC_GoBackward write FC_GoBackward;
|
||||
property C_GoForward: TControl read FC_GoForward write FC_GoForward;
|
||||
end;
|
||||
|
||||
TFHtmFileExp2 = class(TForm)
|
||||
B_OpenHTMLFile: TButton;
|
||||
OpenDialog1: TOpenDialog;
|
||||
P_Top: TPanel;
|
||||
SB_GoBackward: TSpeedButton;
|
||||
SB_GoForward: TSpeedButton;
|
||||
procedure B_OpenHTMLFileClick(Sender: TObject);
|
||||
procedure FormCreate(Sender: TObject);
|
||||
procedure SB_GoBackwardClick(Sender: TObject);
|
||||
procedure SB_GoForwardClick(Sender: TObject);
|
||||
private
|
||||
IpHtmlPanel1: TIpHtmlPanelH;
|
||||
end;
|
||||
|
||||
var
|
||||
FHtmFileExp2: TFHtmFileExp2;
|
||||
|
||||
implementation
|
||||
|
||||
uses
|
||||
IpUtils;
|
||||
|
||||
{--------------------------------------}
|
||||
{-PRIVATE----------}
|
||||
|
||||
procedure TIpHtmlPanelH.GoBackFor (GotoBack: Boolean);
|
||||
var
|
||||
Pst: TPst;
|
||||
S: string;
|
||||
SameFile: Boolean;
|
||||
begin
|
||||
if GotoBack
|
||||
then Dec (CurrPos)
|
||||
else Inc (CurrPos);
|
||||
if GotoBack then begin
|
||||
SameFile := SL[CurrPos+1] = SL[CurrPos]
|
||||
end
|
||||
else begin
|
||||
if CurrPos > 0
|
||||
then SameFile := SL[CurrPos-1] = SL[CurrPos]
|
||||
else SameFile := False;
|
||||
end;
|
||||
if SameFile
|
||||
then S := ''
|
||||
else S := SL[CurrPos];
|
||||
Pst := TPst(SL.Objects[CurrPos]);
|
||||
OpenHTMLFile (S, False, True);
|
||||
VScrollPos := Pst.Position;
|
||||
if Assigned (C_GoBackward)
|
||||
then C_GoBackward.Enabled := (SL.Count > 1) and (CurrPos > 0);
|
||||
if Assigned (C_GoForward)
|
||||
then C_GoForward.Enabled := (SL.Count > 1) and (CurrPos < SL.Count-1);
|
||||
end {GoBackFor};
|
||||
|
||||
procedure TIpHtmlPanelH.HTMLGetImageX(Sender: TIpHtmlNode; const URL: string;
|
||||
var Picture: TPicture);
|
||||
var
|
||||
PicCreated: Boolean;
|
||||
FN, nURL: string;
|
||||
{$IFNDEF IP_LAZARUS}
|
||||
Ext: string;
|
||||
BitMap: Graphics.TBitMap;
|
||||
{$ENDIF}
|
||||
begin
|
||||
PicCreated := False;
|
||||
try
|
||||
if PathChanged
|
||||
then FN := Path
|
||||
else FN := ExtractFilePath(SL[CurrPos]);
|
||||
if Pos ('\',FN) <> 0
|
||||
then nURL := NetToDOSPath(URL)
|
||||
else nURL := URL;
|
||||
FN := Concat (FN, nURL);
|
||||
if FileExists(FN) then begin
|
||||
if Picture = nil then begin
|
||||
Picture := TPicture.Create;
|
||||
PicCreated := True;
|
||||
end;
|
||||
{$IFNDEF IP_LAZARUS}
|
||||
Ext := LowerCase (Copy (ExtractFileExt (FN), 2, MaxInt));
|
||||
if (Ext = 'bmp') or (Ext = 'emf') or (Ext = 'wmf') or (Ext = 'gif') or (Ext = 'jpg') then begin
|
||||
{$ENDIF}
|
||||
Picture.LoadFromFile(FN);
|
||||
{$IFNDEF IP_LAZARUS}
|
||||
end
|
||||
else begin
|
||||
PicCreated := False;
|
||||
BitMap := Graphics.TBitMap.Create;
|
||||
with TLinearBitmap.Create do
|
||||
try
|
||||
LoadFromFile (FN);
|
||||
AssignTo (Bitmap);
|
||||
Picture.Bitmap.Assign (BitMap);
|
||||
PicCreated := True;
|
||||
finally
|
||||
Bitmap.Free;
|
||||
Free;
|
||||
end;
|
||||
end;
|
||||
{$ENDIF}
|
||||
end;
|
||||
except
|
||||
if PicCreated then
|
||||
Picture.Free;
|
||||
Picture := nil;
|
||||
end;
|
||||
end {HTMLGetImageX};
|
||||
|
||||
procedure TIpHtmlPanelH.HotClickH(Sender: TObject);
|
||||
begin
|
||||
if HotNode is TIpHtmlNodeA then begin
|
||||
TPst(SL.Objects[CurrPos]).Position := VScrollPos;
|
||||
OpenHTMLFile (TIpHtmlNodeA(HotNode).HRef, True, True);
|
||||
end;
|
||||
end;
|
||||
|
||||
{-PUBLIC-----------}
|
||||
|
||||
constructor TIpHtmlPanelH.Create(AOwner: TComponent);
|
||||
begin
|
||||
inherited;
|
||||
SL := TStringList.Create;
|
||||
CurrPos := -1;
|
||||
OnHotClick := @HotClickH;
|
||||
end;
|
||||
|
||||
destructor TIpHtmlPanelH.Destroy;
|
||||
var
|
||||
I: Integer;
|
||||
begin
|
||||
for I := SL.Count-1 downto 0 do
|
||||
TPst(SL.Objects[I]).Free;
|
||||
SL.Free;
|
||||
inherited;
|
||||
end {Destroy};
|
||||
|
||||
procedure TIpHtmlPanelH.GoBackward;
|
||||
begin
|
||||
TPst(SL.Objects[CurrPos]).Position := VScrollPos;
|
||||
GoBackFor (True);
|
||||
end;
|
||||
|
||||
procedure TIpHtmlPanelH.GoForward;
|
||||
begin
|
||||
GoBackFor (False);
|
||||
end;
|
||||
|
||||
procedure TIpHtmlPanelH.OpenHTMLFile(const Filename: string;
|
||||
ToAdd, RelativePath: Boolean);
|
||||
|
||||
var
|
||||
FN, Anchor: string;
|
||||
Pst: TPst;
|
||||
procedure UpdateSB;
|
||||
var
|
||||
I: Integer;
|
||||
begin
|
||||
if ToAdd then begin
|
||||
Pst := TPst.Create;
|
||||
Pst.Position := VScrollPos;
|
||||
for I := SL.Count-1 downto CurrPos+1 do begin
|
||||
TPst(SL.Objects[I]).Free;
|
||||
SL.Delete(I);
|
||||
end;
|
||||
CurrPos := SL.AddObject (FN, Pst);
|
||||
if Assigned (C_GoBackward)
|
||||
then C_GoBackward.Enabled := SL.Count > 1;
|
||||
if Assigned (C_GoForward)
|
||||
then C_GoForward.Enabled := False;
|
||||
end;
|
||||
end {UpdateSB};
|
||||
|
||||
var
|
||||
fs: TFileStream;
|
||||
NewHTML: TSimpleIpHtml;
|
||||
P: Integer;
|
||||
begin
|
||||
if Filename = '' then begin
|
||||
if CurrPos > -1
|
||||
then VScrollPos := 0;
|
||||
Exit;
|
||||
end;
|
||||
P := Pos ('#', Filename);
|
||||
FN := Filename;
|
||||
if RelativePath then begin
|
||||
PathChanged := False;
|
||||
if P = 0 then begin
|
||||
Anchor := '';
|
||||
end
|
||||
else if P = 1 then begin
|
||||
FN := Concat (Path, CurrFile);
|
||||
Anchor := Copy (Filename, 2, MaxInt);
|
||||
MakeAnchorVisible (Anchor);
|
||||
UpdateSB;
|
||||
Exit;
|
||||
end
|
||||
else begin
|
||||
FN := Copy (Filename, 1, P-1);
|
||||
Anchor := Copy (Filename, P+1, MaxInt);
|
||||
end;
|
||||
if ToAdd then begin
|
||||
FN := Concat (Path, FN);
|
||||
end;
|
||||
end
|
||||
else begin
|
||||
FN := ExpandFileName(FN);
|
||||
CurrFile := ExtractFileName (FN);
|
||||
Path := ExtractFilePath (FN);
|
||||
PathChanged := True;
|
||||
end;
|
||||
try
|
||||
fs := TFileStream.Create (FN, fmOpenRead);
|
||||
try
|
||||
NewHTML := TSimpleIpHtml.Create; // Beware: Will be freed automatically by IpHtmlPanel1
|
||||
NewHTML.OnGetImageX := @HTMLGetImageX;
|
||||
NewHTML.LoadFromStream(fs);
|
||||
SetHtml(NewHTML);
|
||||
if Anchor <> ''
|
||||
then MakeAnchorVisible (Anchor);
|
||||
UpdateSB;
|
||||
finally
|
||||
fs.Free;
|
||||
end;
|
||||
except
|
||||
on E: Exception do begin
|
||||
MessageDlg ('Unable to open HTML file'+sLineBreak+
|
||||
'HTML File: '+Filename+sLineBreak+
|
||||
'Error: '+E.Message, mtError, [mbCancel], 0);
|
||||
end;
|
||||
end;
|
||||
end {OpenHTMLFile};
|
||||
|
||||
{--------------------------------------}
|
||||
{-EVENTS-----------}
|
||||
|
||||
procedure TFHtmFileExp2.FormCreate(Sender: TObject);
|
||||
begin
|
||||
IpHtmlPanel1 := TIpHtmlPanelH.Create (Application);
|
||||
with IpHtmlPanel1 do begin
|
||||
Name := 'IpHtmlPanel';
|
||||
Parent := FHtmFileExp2;
|
||||
Align := alClient;
|
||||
FactBAParag := 0.5;
|
||||
C_GoBackward := SB_GoBackward;
|
||||
C_GoForward := SB_GoForward;
|
||||
OpenHTMLFile ('Index.html', True, False);
|
||||
end;
|
||||
end {FormCreate};
|
||||
|
||||
procedure TFHtmFileExp2.B_OpenHTMLFileClick(Sender: TObject);
|
||||
begin
|
||||
if OpenDialog1.Execute then begin
|
||||
IpHtmlPanel1.OpenHtmlFile (OpenDialog1.FileName, True, False);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TFHtmFileExp2.SB_GoBackwardClick(Sender: TObject);
|
||||
begin
|
||||
IpHtmlPanel1.GoBackward;
|
||||
end;
|
||||
|
||||
procedure TFHtmFileExp2.SB_GoForwardClick(Sender: TObject);
|
||||
begin
|
||||
IpHtmlPanel1.GoForward;
|
||||
end;
|
||||
|
||||
{--------------------------------------}
|
||||
|
||||
initialization
|
||||
{$I htmfileexp2.lrs}
|
||||
{$I defaultimage.lrs}
|
||||
|
||||
end.
|
||||
|
||||
99
components/turbopower_ipro/examples/htmfileexplorer1.lpi
Normal file
99
components/turbopower_ipro/examples/htmfileexplorer1.lpi
Normal file
@ -0,0 +1,99 @@
|
||||
<?xml version="1.0"?>
|
||||
<CONFIG>
|
||||
<ProjectOptions>
|
||||
<PathDelim Value="\"/>
|
||||
<Version Value="5"/>
|
||||
<General>
|
||||
<MainUnit Value="0"/>
|
||||
<IconPath Value="./"/>
|
||||
<TargetFileExt Value=".exe"/>
|
||||
<Title Value="HtmFileExplorer1"/>
|
||||
<ActiveEditorIndexAtStart Value="1"/>
|
||||
</General>
|
||||
<VersionInfo>
|
||||
<ProjectVersion Value=""/>
|
||||
<Language Value=""/>
|
||||
<CharSet Value=""/>
|
||||
</VersionInfo>
|
||||
<PublishOptions>
|
||||
<Version Value="2"/>
|
||||
<IgnoreBinaries Value="False"/>
|
||||
<IncludeFileFilter Value="*.(pas|pp|inc|lfm|lpr|lrs|lpi|lpk|sh|xml)"/>
|
||||
<ExcludeFileFilter Value="*.(bak|ppu|ppw|o|so);*~;backup"/>
|
||||
</PublishOptions>
|
||||
<RunParams>
|
||||
<local>
|
||||
<FormatVersion Value="1"/>
|
||||
<LaunchingApplication PathPlusParams="/usr/X11R6/bin/xterm -T 'Lazarus Run Output' -e $(LazarusDir)/tools/runwait.sh $(TargetCmdLine)"/>
|
||||
</local>
|
||||
</RunParams>
|
||||
<RequiredPackages Count="3">
|
||||
<Item1>
|
||||
<PackageName Value="TurboPowerIPro"/>
|
||||
<MinVersion Major="1" Valid="True"/>
|
||||
</Item1>
|
||||
<Item2>
|
||||
<PackageName Value="LCL"/>
|
||||
<MinVersion Major="1" Valid="True"/>
|
||||
</Item2>
|
||||
<Item3>
|
||||
<PackageName Value="JPEGForLazarus"/>
|
||||
</Item3>
|
||||
</RequiredPackages>
|
||||
<Units Count="2">
|
||||
<Unit0>
|
||||
<Filename Value="htmfileexplorer1.lpr"/>
|
||||
<IsPartOfProject Value="True"/>
|
||||
<CursorPos X="18" Y="8"/>
|
||||
<TopLine Value="1"/>
|
||||
<EditorIndex Value="0"/>
|
||||
<UsageCount Value="20"/>
|
||||
<Loaded Value="True"/>
|
||||
</Unit0>
|
||||
<Unit1>
|
||||
<Filename Value="htmfileexp1.pas"/>
|
||||
<ComponentName Value="FHtmFileExp1"/>
|
||||
<HasResources Value="True"/>
|
||||
<ResourceFilename Value="htmfileexp1.lrs"/>
|
||||
<UnitName Value="HtmFileExp1"/>
|
||||
<CursorPos X="2" Y="6"/>
|
||||
<TopLine Value="1"/>
|
||||
<EditorIndex Value="1"/>
|
||||
<UsageCount Value="10"/>
|
||||
<Loaded Value="True"/>
|
||||
</Unit1>
|
||||
</Units>
|
||||
<JumpHistory Count="0" HistoryIndex="-1"/>
|
||||
</ProjectOptions>
|
||||
<CompilerOptions>
|
||||
<Version Value="5"/>
|
||||
<PathDelim Value="\"/>
|
||||
<SearchPaths>
|
||||
<OtherUnitFiles Value="$(LazarusDir)\components\units\$(TargetCPU)\$(TargetOS)\"/>
|
||||
<SrcPath Value="$(LazarusDir)\lcl\;$(LazarusDir)\lcl\interfaces\$(LCLWidgetType)\"/>
|
||||
</SearchPaths>
|
||||
<CodeGeneration>
|
||||
<Generate Value="Faster"/>
|
||||
</CodeGeneration>
|
||||
<Linking>
|
||||
<Options>
|
||||
<Win32>
|
||||
<GraphicApplication Value="True"/>
|
||||
</Win32>
|
||||
</Options>
|
||||
</Linking>
|
||||
<Other>
|
||||
<CompilerPath Value="$(CompPath)"/>
|
||||
</Other>
|
||||
</CompilerOptions>
|
||||
<Debugging>
|
||||
<Exceptions Count="2">
|
||||
<Item1>
|
||||
<Name Value="ECodetoolError"/>
|
||||
</Item1>
|
||||
<Item2>
|
||||
<Name Value="EFOpenError"/>
|
||||
</Item2>
|
||||
</Exceptions>
|
||||
</Debugging>
|
||||
</CONFIG>
|
||||
16
components/turbopower_ipro/examples/htmfileexplorer1.lpr
Normal file
16
components/turbopower_ipro/examples/htmfileexplorer1.lpr
Normal file
@ -0,0 +1,16 @@
|
||||
program HtmFileExplorer1;
|
||||
|
||||
{$mode objfpc}{$H+}
|
||||
|
||||
uses
|
||||
//MemCheck,
|
||||
Interfaces,
|
||||
Forms, HtmFileExp1, JPEGForLazarus;
|
||||
|
||||
begin
|
||||
Application.Title:='HtmFileExplorer1';
|
||||
Application.Initialize;
|
||||
Application.CreateForm(TFHtmFileExp1, FHtmFileExp1);
|
||||
Application.Run;
|
||||
end.
|
||||
|
||||
127
components/turbopower_ipro/examples/htmfileexplorer2.lpi
Normal file
127
components/turbopower_ipro/examples/htmfileexplorer2.lpi
Normal file
@ -0,0 +1,127 @@
|
||||
<?xml version="1.0"?>
|
||||
<CONFIG>
|
||||
<ProjectOptions>
|
||||
<PathDelim Value="\"/>
|
||||
<Version Value="5"/>
|
||||
<General>
|
||||
<MainUnit Value="0"/>
|
||||
<IconPath Value="./"/>
|
||||
<TargetFileExt Value=".exe"/>
|
||||
<Title Value="HtmFileExplorer2"/>
|
||||
<ActiveEditorIndexAtStart Value="0"/>
|
||||
</General>
|
||||
<VersionInfo>
|
||||
<ProjectVersion Value=""/>
|
||||
<Language Value=""/>
|
||||
<CharSet Value=""/>
|
||||
</VersionInfo>
|
||||
<PublishOptions>
|
||||
<Version Value="2"/>
|
||||
<IgnoreBinaries Value="False"/>
|
||||
<IncludeFileFilter Value="*.(pas|pp|inc|lfm|lpr|lrs|lpi|lpk|sh|xml)"/>
|
||||
<ExcludeFileFilter Value="*.(bak|ppu|ppw|o|so);*~;backup"/>
|
||||
</PublishOptions>
|
||||
<RunParams>
|
||||
<local>
|
||||
<FormatVersion Value="1"/>
|
||||
<LaunchingApplication PathPlusParams="/usr/X11R6/bin/xterm -T 'Lazarus Run Output' -e $(LazarusDir)/tools/runwait.sh $(TargetCmdLine)"/>
|
||||
</local>
|
||||
</RunParams>
|
||||
<RequiredPackages Count="3">
|
||||
<Item1>
|
||||
<PackageName Value="TurboPowerIPro"/>
|
||||
<MinVersion Major="1" Valid="True"/>
|
||||
</Item1>
|
||||
<Item2>
|
||||
<PackageName Value="LCL"/>
|
||||
<MinVersion Major="1" Valid="True"/>
|
||||
</Item2>
|
||||
<Item3>
|
||||
<PackageName Value="JPEGForLazarus"/>
|
||||
</Item3>
|
||||
</RequiredPackages>
|
||||
<Units Count="4">
|
||||
<Unit0>
|
||||
<Filename Value="htmfileexplorer2.lpr"/>
|
||||
<IsPartOfProject Value="True"/>
|
||||
<CursorPos X="19" Y="5"/>
|
||||
<TopLine Value="1"/>
|
||||
<UsageCount Value="23"/>
|
||||
</Unit0>
|
||||
<Unit1>
|
||||
<Filename Value="htmfileexp2.pas"/>
|
||||
<ComponentName Value="FHtmFileExp2"/>
|
||||
<HasResources Value="True"/>
|
||||
<ResourceFilename Value="htmfileexp2.lrs"/>
|
||||
<UnitName Value="HtmFileExp2"/>
|
||||
<CursorPos X="12" Y="249"/>
|
||||
<TopLine Value="242"/>
|
||||
<UsageCount Value="11"/>
|
||||
</Unit1>
|
||||
<Unit2>
|
||||
<Filename Value="htmfileexplorer1.lpr"/>
|
||||
<UnitName Value="HtmFileExplorer1"/>
|
||||
<CursorPos X="15" Y="8"/>
|
||||
<TopLine Value="1"/>
|
||||
<EditorIndex Value="0"/>
|
||||
<UsageCount Value="10"/>
|
||||
<Loaded Value="True"/>
|
||||
</Unit2>
|
||||
<Unit3>
|
||||
<Filename Value="htmfileexp1.pas"/>
|
||||
<ComponentName Value="FHtmFileExp1"/>
|
||||
<HasResources Value="True"/>
|
||||
<ResourceFilename Value="htmfileexp1.lrs"/>
|
||||
<UnitName Value="HtmFileExp1"/>
|
||||
<CursorPos X="1" Y="1"/>
|
||||
<TopLine Value="11"/>
|
||||
<EditorIndex Value="1"/>
|
||||
<UsageCount Value="10"/>
|
||||
<Loaded Value="True"/>
|
||||
</Unit3>
|
||||
</Units>
|
||||
<JumpHistory Count="1" HistoryIndex="0">
|
||||
<Position1>
|
||||
<Filename Value="htmfileexplorer1.lpr"/>
|
||||
<Caret Line="8" Column="15" TopLine="1"/>
|
||||
</Position1>
|
||||
</JumpHistory>
|
||||
</ProjectOptions>
|
||||
<CompilerOptions>
|
||||
<Version Value="5"/>
|
||||
<PathDelim Value="\"/>
|
||||
<SearchPaths>
|
||||
<OtherUnitFiles Value="$(LazarusDir)\components\units\$(TargetCPU)\$(TargetOS)\"/>
|
||||
<SrcPath Value="$(LazarusDir)\lcl\;$(LazarusDir)\lcl\interfaces\$(LCLWidgetType)\"/>
|
||||
</SearchPaths>
|
||||
<CodeGeneration>
|
||||
<Generate Value="Faster"/>
|
||||
</CodeGeneration>
|
||||
<Linking>
|
||||
<Options>
|
||||
<Win32>
|
||||
<GraphicApplication Value="True"/>
|
||||
</Win32>
|
||||
</Options>
|
||||
</Linking>
|
||||
<Other>
|
||||
<CompilerPath Value="$(CompPath)"/>
|
||||
</Other>
|
||||
</CompilerOptions>
|
||||
<Debugging>
|
||||
<BreakPoints Count="1">
|
||||
<Item1>
|
||||
<Source Value="htmfileexp2.pas"/>
|
||||
<Line Value="60"/>
|
||||
</Item1>
|
||||
</BreakPoints>
|
||||
<Exceptions Count="2">
|
||||
<Item1>
|
||||
<Name Value="ECodetoolError"/>
|
||||
</Item1>
|
||||
<Item2>
|
||||
<Name Value="EFOpenError"/>
|
||||
</Item2>
|
||||
</Exceptions>
|
||||
</Debugging>
|
||||
</CONFIG>
|
||||
16
components/turbopower_ipro/examples/htmfileexplorer2.lpr
Normal file
16
components/turbopower_ipro/examples/htmfileexplorer2.lpr
Normal file
@ -0,0 +1,16 @@
|
||||
program HtmFileExplorer2;
|
||||
|
||||
{$mode objfpc}{$H+}
|
||||
|
||||
uses
|
||||
//MemCheck,
|
||||
Interfaces,
|
||||
Forms, HtmFileExp2, JPEGForLazarus;
|
||||
|
||||
begin
|
||||
Application.Title:='HtmFileExplorer2';
|
||||
Application.Initialize;
|
||||
Application.CreateForm(TFHtmFileExp2, FHtmFileExp2);
|
||||
Application.Run;
|
||||
end.
|
||||
|
||||
34
components/turbopower_ipro/examples/index.html
Normal file
34
components/turbopower_ipro/examples/index.html
Normal file
@ -0,0 +1,34 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
<html>
|
||||
<head>
|
||||
<meta http-equiv="content-type"
|
||||
content="text/html; charset=ISO-8859-1">
|
||||
<title>Test Page for IPro HTML control for Lazarus</title>
|
||||
</head>
|
||||
<body>
|
||||
<p>Lazarus example for IPro HTML control.<br>
|
||||
<br>
|
||||
Image ../../docs/images/cheetah1.png
|
||||
<br>
|
||||
<img src="../../docs/images/cheetah1.png" title="" alt="cheetah.png image"
|
||||
style="width: 250px; height: 188px;"><br>
|
||||
<br>
|
||||
Image ../../docs/images/laztitle.jpg
|
||||
<br>
|
||||
<img src="../../docs/images/laztitle.jpg" title="" alt="laztitle.jpg image"
|
||||
style="width: 250px; height: 188px;"><br>
|
||||
<br>
|
||||
Image broken
|
||||
<br>
|
||||
<img src="../../docs/images/cheetah2.png" title="" alt="cheetah.png image"
|
||||
style="width: 250px; height: 188px;"><br>
|
||||
<br>
|
||||
<a href="simplepage2.html">Link</a> (to simplepage2.html)</p>
|
||||
<p><strong>Amo</strong><br>
|
||||
<a href="simplepage2.html#morala">Amo kiel morala nocio</a><br>
|
||||
<a href="simplepage2.html#metafizika">Amo kiel metafizika nocio</a></p>
|
||||
<h2></h2>
|
||||
<p><br>
|
||||
</p>
|
||||
</body>
|
||||
</html>
|
||||
25
components/turbopower_ipro/examples/simplepage2.html
Normal file
25
components/turbopower_ipro/examples/simplepage2.html
Normal file
@ -0,0 +1,25 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
<html>
|
||||
<head>
|
||||
<meta http-equiv="content-type"
|
||||
content="text/html; charset=ISO-8859-1">
|
||||
<title>Simple Page 2</title>
|
||||
</head>
|
||||
<body>
|
||||
<p>Go <a href="index.html">Index.html</a>.</p>
|
||||
<h1><a name="Beginning"></a>Amo</h1>
|
||||
<p>Amo estas profunda emocio pri la ŝatado de alia(j) individuo(j), kun kiu(j) oni sentas sin kunligita. Laŭ la kunteksto la vorto povas komprenigi vastan gamon de signifonuancoj de forta simpatio ĝis amora pasio. Amo estas ofta temo en arto, literaturo, poezio kaj kino. Fido estas rigardata ĝia nepra kondiĉo.</p>
|
||||
<p> <strong>Enhavo
|
||||
[kaŝu]</strong><br>
|
||||
<a href="#morala">Amo kiel morala nocio</a><br>
|
||||
<a href="#metafizika">Amo kiel metafizika nocio</a></p>
|
||||
<h2> <a name="morala"></a>Amo kiel morala nocio</h2>
|
||||
<p>Amo en morala senco ne estas tiu amo, kiu estas la ĉeftemo de amromanoj. Amo en morala senco ĉefe estas virto; nome la virto de bonvolemo. Ĝi realiĝas per bonfarado kaj evitado de malbonfarado. "Amo ne faras malbonon al proksimulo; amo do estas la plenumado de la leĝo." (Romanoj 13.10) Ĝi povas havi emocian komponanton, sed ne nepre ĝi havas tre altan emocian temperaturon. Tion atendi, tion postuli estas misinterpreto de la biblia teksto.</p>
|
||||
<p>Por normala homo, sub normalaj cirkonstancoj, ne estas eble, emocie ami la tutan homaron. Sed ami ĝin en morala senco, bonvoleme, bonfareme, tio tute eblas. En tiu senco eblas ankaŭ, ami la malamikon. Tio ne signifas, ke oni dolĉemocie, kiel en amromano, rilatu al malamikoj, sed ke oni ĉiukaze traktu ilin kun certa minimumo da bonvolemo. (Ekz. la reguloj de la internacia militojuro estas konkretiĝoj de morala amo al malamiko.)</p>
|
||||
<h2><a name="metafizika"></a>Amo kiel metafizika nocio</h2>
|
||||
<p>"Anstataŭ, ke antaŭ esti amataj, ni maltrankviliĝis pri tiu nepravigebla, nepraviginda ĝibo tia, kia estis nia esteco, anstataŭ ol senti nin kiel troaĵojn, ni nun sentas, ke tiu estado nia estas kunprenita, kaj volata, kune kun ĝiaj plej malgrandaj detaloj, de absoluta libereco, kiun ĝi samtempe kaŭzas, kaj kiun ni propramense volas per nia propra liberpovo. Tio estas la fundamento de la amĝojo, kiam ĝi ekzistas : nin senti ekzisti prave." (Jean-Paul Sartre)</p>
|
||||
<p>Se mi parolus la lingvon de homoj kaj anĝeloj, sed ne havas amon, mi fariĝus sonanta kupro aŭ tintanta cimbalo. 2. Kaj mi posedus la profetpovon, kaj komprenus ĉiujn misterojn, kaj ĉion scion; kaj se mi havus ĉion fidon, tiel ke mi povus formovi montojn, sed ne havas amon, mi estus nenio. 3. Kaj se mi disdonus mian tutan havon por nutri la malsatulojn, kaj se mi lasus mian korpon por forbrulo, sed ne havas amon, per tio mi nenion profitus. 4. Amo longe suferas kaj bonfaras; amo ne envias; amo ne fanfaronas ne ŝveligas sin, 5. ne kondutas nedece, ne celas por si mem, ne koleriĝas, ne pripensas malbonon, 6. ne ĝuas pri maljusteco, sed kunĝojas pri vereco; 7. ĉion toleras, ĉion kredas, ĉion esperas, ĉion eltenas. 8. Amo neniam pereas; sed ĉu estas profetadoj, ili neniiĝos, ĉu lingvoj, ili ĉesiĝos; ĉu estas scio, ĝi neniiĝos. 9. Ĉar ni scias laŭparte, kaj ni profetadas laŭparte; 10. Sed kiam venos perfektaĵo, tiam neniiĝos tio, kio estas laŭparta. 11. Kiam mi estis infano, kiel infano mi parolis, kiel infano mi sentis, kiel infano mi pensis la infanaĵojn; nun fariĝinte plenaĝulo, mi jam forigis la infanaĵojn. 12. Ĉar nun mi vidas per spegulo, malhele; sed tiam okulon ĉe okulo; nun mi konas laŭparte; sed tiam mi konos tiom same, kiel ankaŭ mi estas konita. 13. Restas do nun fido, espero, amo, tiuj tri; kaj la plej granda el ili estas amo.</p>
|
||||
<p><a href="#Beginning">Go beginning </a><br>
|
||||
</p>
|
||||
</body>
|
||||
</html>
|
||||
BIN
components/turbopower_ipro/for_delphi/ipHtml.dcr
Normal file
BIN
components/turbopower_ipro/for_delphi/ipHtml.dcr
Normal file
Binary file not shown.
BIN
components/turbopower_ipro/for_delphi/iphtml.res
Normal file
BIN
components/turbopower_ipro/for_delphi/iphtml.res
Normal file
Binary file not shown.
File diff suppressed because it is too large
Load Diff
@ -267,7 +267,9 @@ end;
|
||||
procedure TIpHTMLPreview.SetZoom(const Value: Integer);
|
||||
var
|
||||
Scale1, Scale2, Scale0: double;
|
||||
{$IFDEF IP_LAZARUS}
|
||||
ClientHeightDbl, ClientWidthDbl: double;
|
||||
{$ENDIF}
|
||||
begin
|
||||
FZoom := Value;
|
||||
{$IFDEF IP_LAZARUS}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user