Search found 439 matches
- Tue Apr 16, 2024 2:41 pm
- Forum: Getting Started with LiveCode - Complete Beginners
- Topic: Styling paragraphs/lines?
- Replies: 44
- Views: 1425
Re: Styling paragraphs/lines?
It’s a personal standalone that is currently being developed. The method which adds an overlay field is much simpler to use than the one which adds/removes ASCII 11 characters but it can be more complex if I need several highlights in a large scrolling field. At this stage of production, I haven't d...
- Tue Apr 16, 2024 7:25 am
- Forum: Getting Started with LiveCode - Complete Beginners
- Topic: Styling paragraphs/lines?
- Replies: 44
- Views: 1425
Re: Styling paragraphs/lines?
Wow, very impressive! I didn't know about the formattedRect and your use of it opens up great perspectives for me. Also, the blendDarken ink is smart. In absolute terms, we could dream of a future version of LC which would manage a few more HTML tags, like "<br>" for example. In any case, thank you ...
- Mon Apr 15, 2024 11:13 am
- Forum: Getting Started with LiveCode - Complete Beginners
- Topic: Styling paragraphs/lines?
- Replies: 44
- Views: 1425
Re: Styling paragraphs/lines?
Nice
This is a simplified version:
This is a simplified version:
Code: Select all
on mouseUp
put the selectedText into savedText
replace cr with numToNativeChar(11) in savedText
put savedText into the selectedText
set the borderwidth of the selectedText to 4
set the bordercolor of the selectedText to "red"
end mouseUp
- Mon Apr 15, 2024 7:25 am
- Forum: Getting Started with LiveCode - Complete Beginners
- Topic: Styling paragraphs/lines?
- Replies: 44
- Views: 1425
Re: Styling paragraphs/lines?
Thanks Craig, that’s a smart solution :) However, if I want to be a perfectionist, placing a semi-transparent element on top of text decreases the contrast of the text and it is no longer black. This is the difference with the concept of background , where the color is placed in a layer lower than t...
- Sat Apr 13, 2024 8:48 am
- Forum: Getting Started with LiveCode - Complete Beginners
- Topic: Styling paragraphs/lines?
- Replies: 44
- Views: 1425
Re: Styling paragraphs/lines?
Oops! Right, that would involve placing CRs in the desired locations, and that would definitely be too complex and not robust enough.richmond62 wrote: ↑Sat Apr 13, 2024 8:26 amDoesn't that mean that your border will go round all the text, not just the paragraphs you want?
- Sat Apr 13, 2024 8:21 am
- Forum: Getting Started with LiveCode - Complete Beginners
- Topic: Styling paragraphs/lines?
- Replies: 44
- Views: 1425
Re: Styling paragraphs/lines?
I tried again using numToChar(11) and it seems to work. on mouseup replace cr with numToNativeChar(11) in fld 1 set the borderwidth of paragraph 1 to 4 of fld 1 to 3 -- > ok end mouseup But we have to replace all CRs typed/pasted by users, and it add complexity. Field script: on returnInField put nu...
- Fri Apr 12, 2024 1:58 pm
- Forum: Getting Started with LiveCode - Complete Beginners
- Topic: Styling paragraphs/lines?
- Replies: 44
- Views: 1425
Re: Styling paragraphs/lines?
Right, I was experimenting in this direction. I think I'll continue like this.richmond62 wrote: ↑Fri Apr 12, 2024 1:27 pmIt is, however, possible to set the backGroundColor to a set of selected lines.
Thank you for all your tests, richmond62
- Fri Apr 12, 2024 12:51 pm
- Forum: Getting Started with LiveCode - Complete Beginners
- Topic: Styling paragraphs/lines?
- Replies: 44
- Views: 1425
Re: Styling paragraphs/lines?
Possibly you could stop looking for paragraphs and start looking for incidents of whichever paragraph demarcator you were using. I don't particularly want to use "paragraphs" but I would like to apply a border (or a background for example) to several "lines" in a scrolling editable field. As it is ...
- Fri Apr 12, 2024 11:42 am
- Forum: Getting Started with LiveCode - Complete Beginners
- Topic: Styling paragraphs/lines?
- Replies: 44
- Views: 1425
Re: Styling paragraphs/lines?
I also tried to play with htmlText and <br> without success
- Fri Apr 12, 2024 10:30 am
- Forum: Getting Started with LiveCode - Complete Beginners
- Topic: Styling paragraphs/lines?
- Replies: 44
- Views: 1425
Styling paragraphs/lines?
Hello, I had a look at " How do I style paragraphs in a field? " here: https://lessons.livecode.com/m/4071/l/58674-how-do-i-style-paragraphs-in-a-field So, with the following code, I have: set the bordercolor of paragraph 2 to 4 of field 1 to "green" set the borderwidth of paragraph 2 to 4 of field ...
- Wed Apr 10, 2024 2:04 pm
- Forum: Getting Started with LiveCode - Complete Beginners
- Topic: How to copy backgroundPattern of a graphic ?
- Replies: 9
- Views: 289
Re: How to copy backgroundPattern of a graphic ?
Thank you richmond62.
BTW, my script deletes the "last image" because, when in development time, I didn't want to store lots a temporary images in my stack.
BTW, my script deletes the "last image" because, when in development time, I didn't want to store lots a temporary images in my stack.
- Wed Apr 10, 2024 1:11 pm
- Forum: Getting Started with LiveCode - Complete Beginners
- Topic: How to copy backgroundPattern of a graphic ?
- Replies: 9
- Views: 289
- Wed Apr 10, 2024 12:47 pm
- Forum: Getting Started with LiveCode - Complete Beginners
- Topic: How to copy backgroundPattern of a graphic ?
- Replies: 9
- Views: 289
How to copy backgroundPattern of a graphic ?
Hello How can I copy the backgroundPattern from one graphic control to another? Here is how I populate the backgroundPattern of a first graphic with an image: set the backGroundPattern of graphic "Graphic1" to (the id of last image) delete last image I would now a second graphic to have the same bac...
- Wed Apr 10, 2024 10:49 am
- Forum: Getting Started with LiveCode - Experienced Developers
- Topic: send in time?
- Replies: 2
- Views: 252
Re: send in time?
Thank you LCMark for this precise and complete response. In the specific case of launching a standalone, in which I have to wait for large substacks to load, what kind of script do you recommend? ---------------------------- kind A on preOpenStack insert the script of stack "CustomErrorReport" into ...
- Wed Apr 10, 2024 8:51 am
- Forum: Getting Started with LiveCode - Experienced Developers
- Topic: send in time?
- Replies: 2
- Views: 252
send in time?
Hello, Just to be sure, do the following scripts do the exact same things, at the same time? on myProcess_A send "myProcess_B" to me in 100 milliseconds end myProcess_A on myProcess_B put the date into fld 1 end myProcess_B on myProcess wait 100 milliseconds with messages put the date into fld 1 end...