EvilZone
Programming and Scripting => Projects and Discussion => : relax November 16, 2012, 11:04:09 AM
-
so writing a small script in autoit v3 and im totaly new and dont even know if the program is powerful enouf
so i want the program to write out clipboard content with different font type
im using autoit because it has a easy
WinActivate()
function
heres the problem:
when i copy text to my clipboard it is formated with size and type
when i paste it to the window i want it to, the pasted text format persists witch is good.
but i want to change the font type and possible the font size.
im a bit comfused because ill use a Raw clipviewer and the text dose not have any tags or code its just clear text.
if this cant be done in autoit im open for sugestions for other languages.
Edit: actually it dosent have to have anything with clipboard to do because its going to be reading from a text file.
Relax formated text(http://evilzone.org/data:image/gif,GIF89a%12%00%12%00%B3%00%00%FF%FF%FF%F7%F7%EF%CC%CC%CC%BD%BE%BD%99%99%99ZYZRUR%00%00%00%FE%01%02%00%00%00%00%00%00%00%00%00%00%00%00%00%00%00%00%00%00%00%00%00!%F9%04%04%14%00%FF%00%2C%00%00%00%00%12%00%12%00%00%04X0%C8I%2B%1D8%EB%3D%E4%00%60(%8A%85%17%0AG*%8C%40%19%7C%00J%08%C4%B1%92%26z%C76%FE%02%07%C2%89v%F0%7Dz%C3b%C8u%14%82V5%23o%A7%13%19L%BCY-%25%7D%A6l%DF%D0%F5%C7%02%85%5B%D82%90%CBT%87%D8i7%88Y%A8%DB%EFx%8B%DE%12%01%00%3B)(http://evilzone.org/data:image/gif,GIF89a%12%00%12%00%B3%00%00%FF%FF%FF%F7%F7%EF%CC%CC%CC%BD%BE%BD%99%99%99ZYZRUR%00%00%00%FE%01%02%00%00%00%00%00%00%00%00%00%00%00%00%00%00%00%00%00%00%00%00%00!%F9%04%04%14%00%FF%00%2C%00%00%00%00%12%00%12%00%00%04X0%C8I%2B%1D8%EB%3D%E4%00%60(%8A%85%17%0AG*%8C%40%19%7C%00J%08%C4%B1%92%26z%C76%FE%02%07%C2%89v%F0%7Dz%C3b%C8u%14%82V5%23o%A7%13%19L%BCY-%25%7D%A6l%DF%D0%F5%C7%02%85%5B%D82%90%CBT%87%D8i7%88Y%A8%DB%EFx%8B%DE%12%01%00%3B)
-
Take a look here is a udf made from a user in AutoIt forum.( yes it can be done )
http://www.autoitscript.com/forum/topic/81267-clipboard-getall-clipboard-putall-clipboard-wait/
-
hmm that dossent change the font type of clipboard or even show the format type in clipboard
:/
-
Relax if i understand correctly you want to print the content of your clipboard in your AutoIt Gui with a font of your choise ?
Something like that
#include <GUIConstantsEx.au3>
Example()
Func Example()
Local $font, $msg
GUICreate("My GUI default font") ; will create a dialog box that when displayed is centered
$font = "Comic Sans MS"
GUISetFont(9, 400, 4, $font) ; will display underlined characters
GUICtrlCreateLabel("underlined label", 10, 20)
GUISetFont(9, 400, 2, $font) ; will display underlined characters
GUICtrlCreateLabel("italic label", 10, 40)
GUISetFont(9, 400, 8, $font) ; will display underlined characters
GUICtrlCreateLabel("strike label", 10, 60)
GUISetState()
; Run the GUI until the dialog is closed
While 1
$msg = GUIGetMsg()
If $msg = $GUI_EVENT_CLOSE Then ExitLoop
WEnd
EndFunc ;==>Example
-
nah i wanted to print out the clipboard to an active window (not mine window) with a different font. sry if that was unclear
but after more investegation i realised that the window i want to paste it to dossent support font style, the reason i saw other font styles in the window was because they where written in english by japanese "coding"...
so ill guess ill go back to my previus problem of finding the font that is used in the "active window"
tryed font identifiers but no luck
so if anyone can identify this font id be grateful
edit: yeah tryed online font identifiers and they give me tetria witch is wrong
-
You lost me man, anyway the font must be FF Utility
-
You lost me man, anyway the font must be FF Utility
nah its not FF Utility
have no idea whats wrong with me latley but i have been thinking like a complete idiot it seems
The font is most likley Tahoma 12pt
admins may lock this.
and geXXos thanks for your help :)
-
There is a difference between RichText and PlainText. If you're reading from a TXT file, then it's just plain text and the way that text appears depends on the viewer. So it if you copy from one viewer and paste it to the same viewer, it's gonna be identical, but if you paste it to some other viewer then it's gonna be like it was.
With richtext you can c/p shit but normal viewers won't read it.
So like you said, there are no tags and extra bytes, so it's plain text and you cannot change any attributes to it.
You could if the text was in HTML form and RTF form.