Richedit control - margin with line numbers
Richedit control - margin with line numbers
Hello
I do not ask about GUI things very much because there are lot of examples around net
but not about this one...
My question is :
is there a any example or piece of code (routines) to add line numbers into richedit control margin
thanks
I do not ask about GUI things very much because there are lot of examples around net
but not about this one...
My question is :
is there a any example or piece of code (routines) to add line numbers into richedit control margin
thanks
-
- Posts: 783
- Joined: Jul 26, 2018 18:28
Re: Richedit control - margin with line numbers
Here you can:
Code: Select all
Dim fmt As ParaFormat2
fmt.cbSize = SizeOf(fmt)
fmt.dwMask = PFM_NUMBERING Or PFM_NUMBERINGSTART Or PFM_NUMBERINGSTYLE Or PFM_NUMBERINGTAB
fmt.wNumbering = 2
fmt.wNumberingStart = 1
fmt.wNumberingStyle = PFNS_PERIOD
SendMessage hwndRichEdit, EM_SETPARAFORMAT, 0, Cast(lParam, @fmt)
Re: Richedit control - margin with line numbers
Thanks i will try...
Re: Richedit control - margin with line numbers
It works only to a certain extent, Aurel, see here.
Re: Richedit control - margin with line numbers
It works excellent ...i mean qWord example in masm32
look on forum...
look on forum...
Re: Richedit control - margin with line numbers
It works excellent for small sources. Above 32768 lines it goes crazy.
Re: Richedit control - margin with line numbers
Could somebody post a little intact example to run.
I was messing about making a code editor, so line numbers are a must.
Thank you.
I was messing about making a code editor, so line numbers are a must.
Thank you.
Re: Richedit control - margin with line numbers
See here for a better solution. I have never missed line numbers. If there is an error in my source, the editor jumps to that line, so why should I see the line number all the time to the left of my source? Of course, it should be available somewhere, in the status bar for example. But I would never allow an editor to waste valuable space for permanent line numbers.dodicat wrote:I was messing about making a code editor, so line numbers are a must.
Here is a demo showing line numbers in a RichEdit control. I find it awful.
Re: Richedit control - margin with line numbers
Thanks jj2007.
I use fbide, line numbers can be turned off, the cursor jumps to an offending compile error anyway.
But I would like an example of fb code and rich edit and line numbers.
I suppose I could mess around myself and get there eventually, but I feel a bit lazy tonight.
I use fbide, line numbers can be turned off, the cursor jumps to an offending compile error anyway.
But I would like an example of fb code and rich edit and line numbers.
I suppose I could mess around myself and get there eventually, but I feel a bit lazy tonight.
Re: Richedit control - margin with line numbers
Xusinboy's solution works.dodicat wrote:But I would like an example of fb code and rich edit and line numbers.
I suppose I could mess around myself and get there eventually, but I feel a bit lazy tonight.
Re: Richedit control - margin with line numbers
come on JJ, which hobby programmer need such a large amount of lines?Above 32768 lines it goes crazy
and for me line numbers are standard for any editor
Re: Richedit control - margin with line numbers
WOW
hey JJ
Is it normal that admin on masm forum is so unfriendly?
And what is wrong in asking for help?
that is really strange...
hey JJ
Is it normal that admin on masm forum is so unfriendly?
And what is wrong in asking for help?
that is really strange...
Re: Richedit control - margin with line numbers
No, that's normal, Aurel. He is a nice guy otherwise, but don't dare to bring disorder in his house ;-)
Re: Richedit control - margin with line numbers
Normal...
ahh yeah attack is the best defend..heh
it looks to me that he reacted when i say OxygenBasic.
It seems to me that many people on other forums don't like it ...ahh long story
ahh yeah attack is the best defend..heh
it looks to me that he reacted when i say OxygenBasic.
It seems to me that many people on other forums don't like it ...ahh long story
Re: Richedit control - margin with line numbers
Yea well, I think Hutch has got a problem.
Mnemonic Driven API Grinder doesn't seem too laid back to me.
Nil desperandum carburundum seems appropriate.
I dowloaded oxygen basic, and it looked promising, but my AVIRA got it on the first example, and it now lies in the quarantine pit.
Never mind.
Mnemonic Driven API Grinder doesn't seem too laid back to me.
Nil desperandum carburundum seems appropriate.
I dowloaded oxygen basic, and it looked promising, but my AVIRA got it on the first example, and it now lies in the quarantine pit.
Never mind.