<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
	<title type="html"><![CDATA[Серый форум &mdash; AHK: Вставить изображение.png в скрипт]]></title>
	<link rel="self" href="http://forum.script-coding.com/extern.php?action=feed&amp;tid=11681&amp;type=atom" />
	<updated>2016-06-06T19:16:43Z</updated>
	<generator>PunBB</generator>
	<id>http://forum.script-coding.com/viewtopic.php?id=11681</id>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Вставить изображение.png в скрипт]]></title>
			<link rel="alternate" href="http://forum.script-coding.com/viewtopic.php?pid=104853#p104853" />
			<content type="html"><![CDATA[<p>А так?<br /></p><div class="codebox"><pre><code>;#######################################################################
2osx := 1905
2osx += 852
1osx := A_ScreenWidth
1osx /= 2
1osx -= 456
#SingleInstance, Force
#NoEnv
SetBatchLines, -1
#Include, Gdip.ahk
pToken := Gdip_Startup()
OnExit, Exit
Gui, 1: -Caption +E0x80000 +LastFound +AlwaysOnTop +ToolWindow +OwnDialogs
Gui, 1: Show, NA
hwnd1 := WinExist()
pBitmap := Gdip_CreateBitmapFromFile(&quot;test.png&quot;)
Width := 2osx, Height := 1836
hbm := CreateDIBSection(Width//2, Height//2)	,hdc := CreateCompatibleDC()
obm := SelectObject(hdc, hbm)	,G := Gdip_GraphicsFromHDC(hdc)
Gdip_SetInterpolationMode(G, 7)
Gdip_DrawImage(G, pBitmap, 1osx, 0, Width//2, Height//2, 0, 0, Width//1, Height//1)
UpdateLayeredWindow(hwnd1, hdc, 0, 0, Width//2, Height//2)
SelectObject(hdc, obm)	,DeleteObject(hbm)	,DeleteDC(hdc)
Gdip_DeleteGraphics(G),	Gdip_DisposeImage(pBitmap)

;#######################################################################
Gui, 2: Add, Picture, x70 y305 w90 h30 gexit, %A_WorkingDir%\выход.jpg
Gui, 2: Show, x0 y0 h342 w231, 
Return

exit:
Gdip_Shutdown(pToken)
ExitApp
return</code></pre></div>]]></content>
			<author>
				<name><![CDATA[ypppu]]></name>
				<uri>http://forum.script-coding.com/profile.php?id=5974</uri>
			</author>
			<updated>2016-06-06T19:16:43Z</updated>
			<id>http://forum.script-coding.com/viewtopic.php?pid=104853#p104853</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Вставить изображение.png в скрипт]]></title>
			<link rel="alternate" href="http://forum.script-coding.com/viewtopic.php?pid=104843#p104843" />
			<content type="html"><![CDATA[<p><strong>ypppu</strong><br />Почему&nbsp; не могу создать GUI?<br />Kогда создаю окно, скрипт закрывается!<br />Мне нужно создать прозрачное окно с кнопками поверх этого изображения!<br /></p><div class="codebox"><pre><code>;#######################################################################
2osx := 1905
2osx += 852
1osx := A_ScreenWidth
1osx /= 2
1osx -= 456
#SingleInstance, Force
#NoEnv
SetBatchLines, -1
#Include, Gdip.ahk
pToken := Gdip_Startup()
OnExit, Exit
Gui, 1: -Caption +E0x80000 +LastFound +AlwaysOnTop +ToolWindow +OwnDialogs
Gui, 1: Show, NA
hwnd1 := WinExist()
pBitmap := Gdip_CreateBitmapFromFile(&quot;test.png&quot;)
Width := 2osx, Height := 1836
hbm := CreateDIBSection(Width//2, Height//2)	,hdc := CreateCompatibleDC()
obm := SelectObject(hdc, hbm)	,G := Gdip_GraphicsFromHDC(hdc)
Gdip_SetInterpolationMode(G, 7)
Gdip_DrawImage(G, pBitmap, 1osx, 0, Width//2, Height//2, 0, 0, Width//1, Height//1)
UpdateLayeredWindow(hwnd1, hdc, 0, 0, Width//2, Height//2)
SelectObject(hdc, obm)	,DeleteObject(hbm)	,DeleteDC(hdc)
Gdip_DeleteGraphics(G),	Gdip_DisposeImage(pBitmap)
;~ Return
;#######################################################################
Gui, Add, button, x70 y305 w90 h30 gexit, ОК
Gui, Show, x0 y0 h342 w231, 
Return

exit:
Gdip_Shutdown(pToken)
ExitApp
return</code></pre></div>]]></content>
			<author>
				<name><![CDATA[minesemka]]></name>
				<uri>http://forum.script-coding.com/profile.php?id=33949</uri>
			</author>
			<updated>2016-06-06T18:43:00Z</updated>
			<id>http://forum.script-coding.com/viewtopic.php?pid=104843#p104843</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Вставить изображение.png в скрипт]]></title>
			<link rel="alternate" href="http://forum.script-coding.com/viewtopic.php?pid=104838#p104838" />
			<content type="html"><![CDATA[<p>Скрипт компилируется вместе со всем, что прилагается через #Include.</p>]]></content>
			<author>
				<name><![CDATA[ypppu]]></name>
				<uri>http://forum.script-coding.com/profile.php?id=5974</uri>
			</author>
			<updated>2016-06-06T17:34:25Z</updated>
			<id>http://forum.script-coding.com/viewtopic.php?pid=104838#p104838</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Вставить изображение.png в скрипт]]></title>
			<link rel="alternate" href="http://forum.script-coding.com/viewtopic.php?pid=104836#p104836" />
			<content type="html"><![CDATA[<p><strong>ypppu</strong><br />а как я должен запустить на другом компьютере Gdip.ahk? Или оно и так работать будет?</p>]]></content>
			<author>
				<name><![CDATA[minesemka]]></name>
				<uri>http://forum.script-coding.com/profile.php?id=33949</uri>
			</author>
			<updated>2016-06-06T17:11:11Z</updated>
			<id>http://forum.script-coding.com/viewtopic.php?pid=104836#p104836</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Вставить изображение.png в скрипт]]></title>
			<link rel="alternate" href="http://forum.script-coding.com/viewtopic.php?pid=104835#p104835" />
			<content type="html"><![CDATA[<p>Компилировать нужно Ваш скрипт, а не библиотеку Gdip.</p>]]></content>
			<author>
				<name><![CDATA[ypppu]]></name>
				<uri>http://forum.script-coding.com/profile.php?id=5974</uri>
			</author>
			<updated>2016-06-06T16:58:04Z</updated>
			<id>http://forum.script-coding.com/viewtopic.php?pid=104835#p104835</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Вставить изображение.png в скрипт]]></title>
			<link rel="alternate" href="http://forum.script-coding.com/viewtopic.php?pid=104830#p104830" />
			<content type="html"><![CDATA[<p><strong>ypppu</strong><br />А можно как нибудь запустить это всё на ПК на котором нет программы AutoHotKey??<br />Скомпилировал Gdip.exe изменил #Include, Gdip.ехе, нечего не работает!</p>]]></content>
			<author>
				<name><![CDATA[minesemka]]></name>
				<uri>http://forum.script-coding.com/profile.php?id=33949</uri>
			</author>
			<updated>2016-06-06T16:19:17Z</updated>
			<id>http://forum.script-coding.com/viewtopic.php?pid=104830#p104830</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Вставить изображение.png в скрипт]]></title>
			<link rel="alternate" href="http://forum.script-coding.com/viewtopic.php?pid=104829#p104829" />
			<content type="html"><![CDATA[<p>Впрочем, версия GDIp.ahk там обновлённая.</p>]]></content>
			<author>
				<name><![CDATA[teadrinker]]></name>
				<uri>http://forum.script-coding.com/profile.php?id=24515</uri>
			</author>
			<updated>2016-06-06T15:21:25Z</updated>
			<id>http://forum.script-coding.com/viewtopic.php?pid=104829#p104829</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Вставить изображение.png в скрипт]]></title>
			<link rel="alternate" href="http://forum.script-coding.com/viewtopic.php?pid=104828#p104828" />
			<content type="html"><![CDATA[<p>Тем более. <img src="//forum.script-coding.com/img/smilies/smile.png" width="15" height="15" /></p>]]></content>
			<author>
				<name><![CDATA[teadrinker]]></name>
				<uri>http://forum.script-coding.com/profile.php?id=24515</uri>
			</author>
			<updated>2016-06-06T15:18:11Z</updated>
			<id>http://forum.script-coding.com/viewtopic.php?pid=104828#p104828</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Вставить изображение.png в скрипт]]></title>
			<link rel="alternate" href="http://forum.script-coding.com/viewtopic.php?pid=104827#p104827" />
			<content type="html"><![CDATA[<p>Эти 2 кода идентичны.</p>]]></content>
			<author>
				<name><![CDATA[Malcev]]></name>
				<uri>http://forum.script-coding.com/profile.php?id=26930</uri>
			</author>
			<updated>2016-06-06T15:17:17Z</updated>
			<id>http://forum.script-coding.com/viewtopic.php?pid=104827#p104827</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Вставить изображение.png в скрипт]]></title>
			<link rel="alternate" href="http://forum.script-coding.com/viewtopic.php?pid=104826#p104826" />
			<content type="html"><![CDATA[<p><strong>ypppu</strong>, зачем пример <strong>yalanne</strong>? <a href="http://forum.script-coding.com/viewtopic.php?pid=104808#p104808">Код</a>, который привёл <strong>Nikva</strong> — рабочий.</p>]]></content>
			<author>
				<name><![CDATA[teadrinker]]></name>
				<uri>http://forum.script-coding.com/profile.php?id=24515</uri>
			</author>
			<updated>2016-06-06T15:11:43Z</updated>
			<id>http://forum.script-coding.com/viewtopic.php?pid=104826#p104826</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Вставить изображение.png в скрипт]]></title>
			<link rel="alternate" href="http://forum.script-coding.com/viewtopic.php?pid=104825#p104825" />
			<content type="html"><![CDATA[<div class="quotebox"><blockquote><p>Полупрозрачные области все равно остаются красными.</p></blockquote></div><p> Правильно, в том коде прозрачным был назначен только цвет fe0000.</p><p><strong>minesemka</strong>, если я правильно понял, требуется поместить в окно изображение, имеющее области с различными степенями прозрачности.</p><p>Была такая тема <a href="http://forum.script-coding.com/viewtopic.php?id=11126">AHK: альфа 32 бита</a>, где <strong>yalanne</strong> выложил пример скрипта.</p>]]></content>
			<author>
				<name><![CDATA[ypppu]]></name>
				<uri>http://forum.script-coding.com/profile.php?id=5974</uri>
			</author>
			<updated>2016-06-06T15:03:13Z</updated>
			<id>http://forum.script-coding.com/viewtopic.php?pid=104825#p104825</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Вставить изображение.png в скрипт]]></title>
			<link rel="alternate" href="http://forum.script-coding.com/viewtopic.php?pid=104822#p104822" />
			<content type="html"><![CDATA[<div class="quotebox"><cite>Nikva пишет:</cite><blockquote><p>Украл где-то на офф форуме, нужна <a href="http://www.autohotkey.net/~tic/Gdip.ahk">GDI+.</a></p></blockquote></div><p>Называется «слышал звон, да не знаю, где он». Ваша ссылка ведёт на файл для AHK-basic, он работает только для 32-битных версий AHK. <a href="https://autohotkey.com/board/topic/29449-gdi-standard-library-145-by-tic/">Страница</a> проэкта на форуме, скачивать <a href="https://www.dropbox.com/s/0e9gdfetbfa8v0o/Gdip_All.ahk">Gdip All</a>.</p>]]></content>
			<author>
				<name><![CDATA[teadrinker]]></name>
				<uri>http://forum.script-coding.com/profile.php?id=24515</uri>
			</author>
			<updated>2016-06-06T14:30:28Z</updated>
			<id>http://forum.script-coding.com/viewtopic.php?pid=104822#p104822</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Вставить изображение.png в скрипт]]></title>
			<link rel="alternate" href="http://forum.script-coding.com/viewtopic.php?pid=104819#p104819" />
			<content type="html"><![CDATA[<p><strong>Nikva</strong><br />А можно как нибудь полупрозрачные тоже сделать прозрачными, а не красными?</p>]]></content>
			<author>
				<name><![CDATA[minesemka]]></name>
				<uri>http://forum.script-coding.com/profile.php?id=33949</uri>
			</author>
			<updated>2016-06-06T14:12:12Z</updated>
			<id>http://forum.script-coding.com/viewtopic.php?pid=104819#p104819</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Вставить изображение.png в скрипт]]></title>
			<link rel="alternate" href="http://forum.script-coding.com/viewtopic.php?pid=104818#p104818" />
			<content type="html"><![CDATA[<p><strong>minesemka</strong><br />У меня все работает. Не пойму, что может идти не так.<br /><strong>ypppu</strong><br />Полупрозрачные области все равно остаются красными.</p>]]></content>
			<author>
				<name><![CDATA[Nikva]]></name>
				<uri>http://forum.script-coding.com/profile.php?id=27416</uri>
			</author>
			<updated>2016-06-06T14:10:21Z</updated>
			<id>http://forum.script-coding.com/viewtopic.php?pid=104818#p104818</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: AHK: Вставить изображение.png в скрипт]]></title>
			<link rel="alternate" href="http://forum.script-coding.com/viewtopic.php?pid=104817#p104817" />
			<content type="html"><![CDATA[<p><strong>ypppu</strong><br />Все ровно не работает!<br />Спасибо что помогаете!<br />Я там ссылку на архив скинул протестируйте пожалуйста может это у меня какие то проблемы</p>]]></content>
			<author>
				<name><![CDATA[minesemka]]></name>
				<uri>http://forum.script-coding.com/profile.php?id=33949</uri>
			</author>
			<updated>2016-06-06T14:09:52Z</updated>
			<id>http://forum.script-coding.com/viewtopic.php?pid=104817#p104817</id>
		</entry>
</feed>
