 |
AutoHotkey Community Let's help each other out
|
| View previous topic :: View next topic |
| Author |
Message |
majkinetor
Joined: 24 May 2006 Posts: 4511 Location: Belgrade
|
Posted: Wed May 16, 2007 10:21 am Post subject: [module] RaGrid 2.0.1.6-4 |
|
|
Note: RaGrid doesn't support Unicode by design and that will probably never change. Its open-source however. _________________

Last edited by majkinetor on Wed Jun 16, 2010 1:40 pm; edited 19 times in total |
|
| Back to top |
|
 |
SKAN
Joined: 26 Dec 2005 Posts: 8688
|
Posted: Wed May 16, 2007 10:38 am Post subject: |
|
|
Thanks!
You are a very kind man!  |
|
| Back to top |
|
 |
PhiLho
Joined: 27 Dec 2005 Posts: 6836 Location: France (near Paris)
|
Posted: Wed May 16, 2007 11:17 am Post subject: |
|
|
Very interesting, an often asked feature.
I played a bit with the test script, to see what we can do.
I had to add more flexibility to the RA_AddRow function.
| Code: | #SingleInstance, force
Gui, +LastFound +Resize
hwnd := WinExist()
RG_Init()
hGrd := RG_Add(hwnd, 4, 4, 500, 300, STYLE_VGRIDLINES | STYLE_GRIDLINES )
RG_AddColumn(hGrd, "cap=Name", "w=150", "ha=2", "ca=2" )
RG_AddColumn(hGrd, "cap=Ext", "w=50", "ha=1", "ca=1")
RG_AddColumn(hGrd, "cap=Time", "w=125", "ha=1", "ca=1")
RG_AddColumn(hGrd, "cap=Size", "w=75", "ha=1", "ca=1")
RG_SetFont(hGrd, "s10 bold, Arial")
RG_SetColors(hGrd, "BAAEEFF G551100 T005588")
Loop %A_WinDir%\*.bmp
{
aCol1 := A_LoopFileName
aCol2 := A_LoopFileExt
FormatTime aCol3, %A_LoopFileTimeModified%, yyyy-MM-dd HH:mm:ss
aCol4 := A_LoopFileSize
RG_AddRow(hGrd, "aCol")
}
RG_SetHdrHeight(hGrd, 30)
RG_SetRowHeight(hGrd, 22)
RG_Sort(hGrd, 0, 1)
Gui, Show, w510 h310
return
GuiClose:
GuiEscape:
ExitApp
InsertInteger(pInteger, ByRef pDest, pOffset = 0, pSize = 4)
{
Loop %pSize% ; Copy each byte in the integer into the structure as raw binary data.
DllCall("RtlFillMemory", "UInt", &pDest + pOffset + A_Index-1, "UInt", 1, "UChar", pInteger >> 8*(A_Index-1) & 0xFF)
}
#Include RaGrid.ahk
|
| Code: | RG_AddRow(hGrd, aColName){
local RAW, colCount
SendMessage GM_GETCOLCOUNT,,,, ahk_id %hGrd%
colCount := ErrorLevel
VarSetCapacity(RAW, 4 * colCount, 0)
Loop %colCount%
{
InsertInteger(&%aColName%%A_Index%, RAW, (A_Index - 1) * 4)
}
SendMessage,GM_ADDROW,0,&RAW,, ahk_id %hGrd%
return ErrorLevel
}
|
_________________
vPhiLho := RegExReplace("Philippe Lhoste", "^(\w{3})\w*\s+\b(\w{3})\w*$", "$1$2") |
|
| Back to top |
|
 |
majkinetor
Joined: 24 May 2006 Posts: 4511 Location: Belgrade
|
Posted: Wed May 16, 2007 11:28 am Post subject: |
|
|
| Skan wrote: | | You are a very kind man! |
You yesterday told me that I am uniquely rude.
How can I be kind and rude at the same time, Skan ?
You want to say that I have multiple personalities like Grumpy or BoBo crew ?
| Philho wrote: | | I had to add more flexibility to the RA_AddRow function. |
I had no intention to present full blown API to this control, nor that will be the case for others until I need them.
The intention was to do initialisation so you can continue where I stop.
BTW, this control is very very capable. There are like 10 demo exe's provided by author that can show you possibilities. There is also a demo loading MDB (Access databse format). It supports checkboxes, images, graphs, buttons and so on as cell types. To fully wrapp its capatibilities extensive job is required. _________________
 |
|
| Back to top |
|
 |
SKAN
Joined: 26 Dec 2005 Posts: 8688
|
Posted: Wed May 16, 2007 11:46 am Post subject: |
|
|
/OffTopic
| majkinetor wrote: | | Skan wrote: | | You are a very kind man! |
You yesterday told me that I am uniquely rude. |
Nobody in this forum would believe that I would say so. Or would they ?
Please check my PM again.
| Skan wrote: | | I like you because of this unique property of yours |
I can assure you that you would not find a single post of mine with that word.
I want to assert again: You are a kind man. You knew I was searching for this but you gave me no hopes, and have posted the solution.
Thank you.  |
|
| Back to top |
|
 |
majkinetor
Joined: 24 May 2006 Posts: 4511 Location: Belgrade
|
Posted: Wed May 16, 2007 11:58 am Post subject: |
|
|
| Quote: | | Nobody in this forum would believe that I would say so. |
Well, there are freaks around, you never know.
| Quote: | | You knew I was searching for this but you gave me no hopes, and have posted the solution. |
Acctually, there are other Extreme Grid controls around, waiting to be found by inocent civilians... some look like Excell in 20K dll... Perhaps when your "client" start to be more demanding
You are welcome.
Now ... if I could only manage to put that 9KB AniGif control online, I guess you will donate ?
Acctually, I have collection of "missing controls" here, like 15 of them collected from different ASM forums in previous days, doing all kind of stuff in ridiculously small dll's - playing videos, simulating paint, lil' hex editors etc... All of these controls together are like 150K, waiting for the civilians to notice them... _________________
 |
|
| Back to top |
|
 |
PhiLho
Joined: 27 Dec 2005 Posts: 6836 Location: France (near Paris)
|
Posted: Wed May 16, 2007 12:04 pm Post subject: |
|
|
Same author made a spreadsheet out of his grid control!
The main problem is that there is no documentation beside the .inc file... _________________
vPhiLho := RegExReplace("Philippe Lhoste", "^(\w{3})\w*\s+\b(\w{3})\w*$", "$1$2") |
|
| Back to top |
|
 |
majkinetor
Joined: 24 May 2006 Posts: 4511 Location: Belgrade
|
Posted: Wed May 16, 2007 12:58 pm Post subject: |
|
|
The docu is provided as bunch of ASM examples along with the inc file. Its not much of a problem. This morning, I found the RaGrid control, looked all ASM examples code and created wrapper of basic functions in an hour. So, if you know enough of Win internals, its not a problem at all, as all of these controls made to follow standard MS rules and ASM code itself reminds me on AHK
You can even register control for entire OS, so any application can create them knowing the class name.
Yup, spreadhseet is one of the 15 "missing controls" I was talking about. _________________

Last edited by majkinetor on Wed May 16, 2007 1:22 pm; edited 1 time in total |
|
| Back to top |
|
 |
daonlyfreez
Joined: 16 Mar 2005 Posts: 949 Location: Berlin
|
Posted: Wed May 16, 2007 1:04 pm Post subject: |
|
|
| Quote: | | Acctually, I have collection of "missing controls" here, like 15 of them collected from different ASM forums in previous days, doing all kind of stuff in ridiculously small dll's - playing videos, simulating paint, lil' hex editors etc... All of these controls together are like 150K, waiting for the civilians to notice them... |
Could you provide a download-link?  _________________
mirror 1 • mirror 2 • mirror 3 • ahk4.me • PM or  |
|
| Back to top |
|
 |
majkinetor
Joined: 24 May 2006 Posts: 4511 Location: Belgrade
|
Posted: Fri Jun 01, 2007 4:18 pm Post subject: |
|
|
A new version, very functional and ready.
The only thing I didn't wrap are notification handlers for text change, button clicks etc. This is fairly trivial to add, but I didn't have time now. _________________
 |
|
| Back to top |
|
 |
mwharri
Joined: 15 Mar 2007 Posts: 70
|
Posted: Fri Jun 01, 2007 4:49 pm Post subject: |
|
|
| majkinetor wrote: | A new version, very functional and ready.
The only thing I didn't wrap are notification handlers for text change, button clicks etc. This is fairly trivial to add, but I didn't have time now. |
Awesome job...I'll work on expanding the properties dialog to include the new functions. I should have a decent amount of work done by the end of the weekend.
Thanks again. |
|
| Back to top |
|
 |
mwharri
Joined: 15 Mar 2007 Posts: 70
|
Posted: Fri Jun 01, 2007 8:54 pm Post subject: |
|
|
| Well, the download link does not include any of the new functions. |
|
| Back to top |
|
 |
majkinetor
Joined: 24 May 2006 Posts: 4511 Location: Belgrade
|
Posted: Sat Jun 02, 2007 2:41 pm Post subject: |
|
|
 _________________
 |
|
| Back to top |
|
 |
majkinetor
Joined: 24 May 2006 Posts: 4511 Location: Belgrade
|
Posted: Tue Jun 19, 2007 9:15 am Post subject: |
|
|
New version
- New API's:
RG_About
RG_ScrollCell
RG_ResetColumns
RG_GetHdrText
RG_SetHdrText
- New control version 2.0.1.5
Wrapper is standardized and the usage is now the same as with any other wrapper I did. _________________
 |
|
| Back to top |
|
 |
Buddy
Joined: 09 Aug 2007 Posts: 11
|
Posted: Wed Nov 07, 2007 7:57 pm Post subject: |
|
|
A very nice control. Two questions arise, when using RaGrid:
1.) Is there a possibility to setup the conrol for multi-line selection and how do i get the set of selected rows ?
2.) How can i detect if and what column header is clicked ?
Thanks |
|
| Back to top |
|
 |
|
|
You can post new topics in this forum You can reply to topics in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|