Scintilla based editor- margins ?

Windows specific questions.
Post Reply
aurelVZAB
Posts: 666
Joined: Jul 02, 2008 14:55
Contact:

Scintilla based editor- margins ?

Post by aurelVZAB »

Hi all...
I have problem how add second margin to scintilla control which can
show marker symbol( similiar like FBEDIT for error line).
I dont understand what i do wrong or maby i use just wrong order of
messages.
Any help will be OK...
Thanks advance ...
Aurel

I have currently this situation:

Code: Select all

  'SendMessage(hwndScintilla,SCI_SETMARGINTYPEN,1,SC_MARGIN_NUMBER )
            'SendMessage(hwndScintilla,SCI_SETMARGINWIDTHN,1,40)
            SendMessage(hwndScintilla,SCI_SETMARGINTYPEN,0,SC_MARGIN_SYMBOL )
            SendMessage(hwndScintilla,SCI_SETMARGINWIDTHN,0,18)
            SendMessage(hwndScintilla,SCI_SETFOLDMARGINCOLOUR,0,BLACK_BRUSH )
            
            SendMessage(hwndScintilla, SCI_MARKERDEFINE, 0, SC_MARK_SHORTARROW )
        		SendMessage(hwndScintilla, SCI_MARKERSETFORE, 0, RGB( 80, 0, 0 ) )
        		SendMessage(hwndScintilla, SCI_MARKERSETBACK, 0, RGB( 255, 0, 0 ) )
            SendMessage(hwndScintilla, SCI_MARKERADD, 1, 0 )
aurelVZAB
Posts: 666
Joined: Jul 02, 2008 14:55
Contact:

Post by aurelVZAB »

So people...
Is anyone have idea how add marker to marker(symbol) margin.
I still dont get it after many try's....
dkl
Site Admin
Posts: 3235
Joined: Jul 28, 2005 14:45
Location: Germany

Post by dkl »

Maybe you need SCI_SETMARGINMASK? If I understand the documentation correctly, it defines what markers a margin can show.
You can also check the return values when sending the messages to see if/where there are errors, that could tell something.

I have no Scintilla test app lying around unfortunately...
aurelVZAB
Posts: 666
Joined: Jul 02, 2008 14:55
Contact:

Post by aurelVZAB »

Thanks dkl...
Problem solved.I will soon add complete code here.
aston
Posts: 16
Joined: Nov 29, 2009 20:32

Post by aston »

Expect soon simple IDE based on scintilla for Free Basic .
Like someone sey here - why not write ide in some other language.
Of course i will present here two version.
One written in FB and one in CB.
FB have some real problems with flickering ....
McLovin
Posts: 82
Joined: Oct 21, 2008 1:15
Contact:

Post by McLovin »

aston wrote: FB have some real problems with flickering ....
I doubt this is an FB problem. More likely the window styles that you are using are redrawing the backgrounds on resize and then the controls on the dialog are also redrawing causing the flicker.
McLovin
Posts: 82
Joined: Oct 21, 2008 1:15
Contact:

Post by McLovin »

What is "CB" ??????
aurelVZAB
Posts: 666
Joined: Jul 02, 2008 14:55
Contact:

Post by aurelVZAB »

Creative Basic.
For example when i use same method in FB and CB in CB there is no
flickering at all.
MichaelW
Posts: 3500
Joined: May 16, 2006 22:34
Location: USA

Post by MichaelW »

In a resizable window with a toolbar and a status bar, the method I have used to eliminate flicker in a Scintilla control is:

Specify the WS_CLIPCHILDREN style for the application window.
Specify the WS_CLIPSIBLINGS style for the Scintilla control.
Set the bRepaint parameter in the MoveWindow call for the Scintilla control in my WM_SIZE handler to FALSE.

While this method has little or no effect for an Edit control, it works reasonably well for a Rich Edit control and very well for a Scintilla control.
aston
Posts: 16
Joined: Nov 29, 2009 20:32

Post by aston »

Ok i will try..
AGS
Posts: 1284
Joined: Sep 25, 2007 0:26
Location: the Netherlands

Post by AGS »

aurelVZAB wrote:Creative Basic.
For example when i use same method in FB and CB in CB there is no
flickering at all.
Creative Basic is no more. The guy developing the interpreter has called it quits. And so another BASIC interpreter bites the dust.
McLovin
Posts: 82
Joined: Oct 21, 2008 1:15
Contact:

Post by McLovin »

When I checked out CB I learned that he also wrote Emergence Basic... also gone. I heard that he had another "Aurora" (a C like language) that he sold off for $1500.
aurelVZAB
Posts: 666
Joined: Jul 02, 2008 14:55
Contact:

Post by aurelVZAB »

Yes Aurora is saled but CB end Emergence Basic still exists and
comunity forum to.
AGS
Posts: 1284
Joined: Sep 25, 2007 0:26
Location: the Netherlands

Post by AGS »

aurelVZAB wrote:Yes Aurora is saled but CB end Emergence Basic still exists and
comunity forum to.
Picked this up from the Creative BASIC site:
NOTE: As of 1/1/2010 Creative BASIC is currently offered as free community supported software.
Emergence BASIC is still out there and Creative BASIC is now... free.

Last update for Creative BASIC was in October 2008 so that's wel over a year ago. And now version 1.01 of Creative BASIC has been released as a free version. CB is, at least in terms of development, as dead as an interpreter can be.

And I'm beginning to wonder why a closed - source developer like you, AurelVZAB, is hanging around on this forum. I'm sure ABasic (written by you?) is nice and all but I don't see no source code, just two executables and a dll. But I'm sure you're either getting ready to release the source code any day now or you've done so already and I somehow cannot find the ABasic source code?
aurelVZAB
Posts: 666
Joined: Jul 02, 2008 14:55
Contact:

Post by aurelVZAB »

Heh why i'm here...good question?
OF course i'm here in first place becose i love basic and of course
Free Basic to .I'm also fascinating with Free Basic capabilities
( i think if someone knows made programs in FB he knows C to ,that is
great..).
Yes i release source code of ABasic somwhere in january of 2008 but
no one have interest for developing this small language with me so i decide
to remove source code from net.
Source code dont offer nothing special and fascinating( beginerly writing
parser- not very well,theres no expression evaluator,there's no api calls
etc...pure experiment).
By the way Aurel Basic is just simple small beginers basic like language.
Ahh Creative is also very very simple language which i capable for
many things but of course is not powerfull like Free Basic .
Post Reply