AltME groups: search
Help · search scripts · search articles · search mailing listresults summary
world | hits |
r4wp | 44 |
r3wp | 965 |
total: | 1009 |
results window for this page: [start: 801 end: 900]
world-name: r3wp
Group: !AltME ... Discussion about AltME [web-public] | ||
Oldes: 16-Mar-2011 | The font issue could be fixed easily if AltME would allow to specify font name or path to font in its settings. | |
shadwolf: 18-Aug-2011 | altme 1.2.25 is invisible in the application circling in gnome3 (alt+ tab) and font are very small ... | |
Endo: 18-Aug-2011 | there is a font option in the message writing area, it makes the font a bit bigger | |
shadwolf: 18-Aug-2011 | so to be direct in rebol fonts a size of 14 = a size of 8 in another font system | |
Group: Core ... Discuss core issues [web-public] | ||
Ashley: 20-Jul-2009 | Here's the finished code (which obtains REBOL compatable font names under Mac): fonts: copy [] caps: make bitset! [#"A" - #"Z"] foreach file compose [(read %/System/Library/Fonts/) (read %/Library/Fonts/)] [ if %.dfont = suffix? file [ s: form first parse file "." parse next s [any [mark: caps (insert mark #" ") 2 skip | skip] end] insert tail fonts s ] ] remove-each font-name fonts: sort unique fonts [ (size-text make face [text: "A" font: make face/font [name: font-name size: 10]]) = size-text make face [text: "A" font: make face/font [name: font-name size: 12]] ] (the windows func to do this is http://www.reboltech.com/library/scripts/get-fonts-windows.r ) | |
Group: Announce ... Announcements only - use Ann-reply to chat [web-public] | ||
Cyphre: 4-Feb-2011 | RMA version of host-kit has been updated: -added support for FreeType2 font handling -fixed text caret crash (thanks to Oldes) you can download the sources here: http://rm-asset.com/code/downloads/files/rma-host-kit.zip | |
Geocaching: 23-Mar-2011 | This does not work with Linux currently ('cause of the font issue) | |
Robert: 2-Oct-2011 | Web-Site updated. See: http://saphirion.com/development/ - the rm-asset.com site is no longer valid, the company was terminated - we use a web-font please let me know if you see any screwed up pages - this R3-GUI release is a huge one, see history Any comments and feedback welcome. | |
Group: !RebGUI ... A lightweight alternative to VID [web-public] | ||
Ashley: 31-Dec-2007 | RebGUI color management. The "old" RebGUI color management system evolved by adding new colors to ctx-rebgui/colors as and when a new color was selected. Many of these colors (e.g. button, tooltip*, btn*) were widget specific. In all, 15 colors were defined. In addition to this, a number of hard-coded colors such as white, black, coal, red and blue were scattered throughout the system. The effect of all this was to provide a means whereby *most* colors could be changed, but the design of a "theme" other than the default WinXP scheme was problematic. The new color management system rationalizes these colors down to a base set of 8, being: page text theme-light theme-dark state-light state-dark outline-light outline-dark with all existing "old" color references being converted to the "new" ones. page and text will usually be white and black (high contrast), with outlines being grey, and theme and state being variations on the same color. The updated request-ui shows how these themes can more easily be chosen (there is a drop-list beneath each of the theme and state groups that sets both light and dark to a similar color). This is still a work in progress, and I am basing the model (and color selections) largely on those described in the "Quilt design style guide"; and colors / ideas from: http://tango.freedesktop.org/Tango_Icon_Theme_Guidelines http://library.gnome.org/devel/gtk/unstable/gtk-Resource-Files.html (styles section) A number of things have to come together to make this work: 1) Conceptual model: do we have the right tokens to reflect all color configurable aspects of the UI (e.g. is there a color word appropriate for a highlight selection, a heading, etc) 2) Are they named appropriately (e.g. is selected better than state-light?) 3) What colors should be used in what context? This last one is very tough. As a general rule I've followed the Quilt model and used outline-light for non-edit edges, theme-dark for edit edges and heading backgrounds, etc (you can find a crude list of usage cases under the new "Colors" tab of RebDOC). But what about a widget like button? It potentially has the following color states: Unselected theme-dark Focus theme-light Button-down ? and widgets such as sheet which might have: Headings theme-dark with page font/color text Cells page Edges outline-light Selected cell theme-light Forumla cell theme-light Cell that cursor is currently over and there are a number of ways of denoting this with color: as a background color change as a font color change as an edge color change as a combination of the above In short, there are a lot of ways of implementing this. What I want needs to be simple and consistent with as few colors as possible. Any suggestions (including links to good color management techniques / approaches) greatly appreciated. | |
Graham: 9-Mar-2008 | Or a symbol font we can sub. | |
BrettH: 18-Jul-2008 | label "Publication : " publication: field 100x8 font [ size: 18 color: black shadow: none ] on-unfocus [ uppercase publication/text ; I'd like to jump to "page" field here ] label "Date :" date: field 30x8 font [ size: 18 color: black shadow: none ] label "Page: " page: field 20x8 font [ size: 18 color: black shadow: none ] return | |
Graham: 19-Jul-2008 | this works do %rebgui.r display "" [ label "Publication : " publication: field 100x8 font [ size: 18 color: black shadow: none ] on-unfocus [ uppercase publication/text ; I'd like to jump to "page" field here ] label "Date :" date: field 30x8 font [ size: 18 color: black shadow: none ] on-focus [ set-focus page false ] label "Page: " page: field 20x8 font [ size: 18 color: black shadow: none ] return ] do-events | |
BrettH: 19-Jul-2008 | Mmm ! Your code sort of does the job, but your forcing the field Date to be skipped by it own on-focus trap which would skip Date always, what I'm trying to do is have Description control the next field to 'visit' depending on what ever test I code in the on-unfocus attached to Description field. for eg: ( pseudo code ) label "Publication : " publication: field 100x8 font [ size: 18 color: black shadow: none ] on-unfocus [ if desc-flag = 1 [ set-focus new-description ] [ set-focus old-description ] ] ==== Your observation of 'reseting' focus back to Description field is an interesting one which I had not considered. | |
Graham: 7-Oct-2008 | the arrows use a symbol font so you need to find the equivalent in Linux. | |
Claude: 25-Oct-2008 | button: make pill [ tip: { USAGE: button "Hello" button -1 "Go!" button "Click me!" [print "click"] DESCRIPTION: Performs action when clicked. OPTIONS: 'info specifies read-only } size: 15x5 text: "" color: colors/theme-dark keep-color: color font: default-font-heading feel: make feel [ over: make function! [face act pos] [ probe face/color set-color face either all [act not find face/options 'info] [colors/theme-light] [face/keep-color] ] engage: make function! [face act event /local f] [ unless find face/options 'info [ do select [ down [set-color face colors/state-light] alt-down [set-color face colors/state-light] up [set-color face colors/theme-dark face/action/on-click face] alt-up [set-color face colors/theme-dark face/action/on-alt-click face] away [set-color face colors/theme-dark] ] act ] ] ] rebind: make function! [] [ color: colors/theme-dark ] init: make function! [] [ all [negative? size/x size/x: 10000 size/x: 8 + first size-text self] all [find options 'info color = colors/theme-dark color: colors/outline-light] keep-color: color action/on-resize self ] ] | |
Claude: 25-Oct-2008 | button: make pill [ tip: { USAGE: button "Hello" button -1 "Go!" button "Click me!" [print "click"] DESCRIPTION: Performs action when clicked. OPTIONS: 'info specifies read-only } size: 15x5 text: "" color: colors/theme-dark keep-color: color font: default-font-heading feel: make feel [ over: make function! [face act pos] [ probe face/color set-color face either all [act not find face/options 'info] [colors/theme-light] [face/keep-color] ] engage: make function! [face act event /local f] [ unless find face/options 'info [ do select [ down [set-color face colors/state-light] alt-down [set-color face colors/state-light] up [set-color face colors/theme-dark face/action/on-click face] alt-up [set-color face colors/theme-dark face/action/on-alt-click face] away [set-color face face/keep-color] ] act ] ] ] rebind: make function! [] [ color: colors/theme-dark ] init: make function! [] [ all [negative? size/x size/x: 10000 size/x: 8 + first size-text self] all [find options 'info color = colors/theme-dark color: colors/outline-light] keep-color: color action/on-resize self ] ] | |
Louis: 30-May-2009 | Graham and Izkata, thanks for the help. But I must be misunderstanding something, as it is still not working. Here is what I have: CONNECT/create/flat %cl.db if error? err: try [ SQL "select * from projects" ][ er: disarm err if find er/arg1 "no such table" [ SQL "create table projects (Priority, ProjectName, ExchangeRate, Objectives, Deliverables)" ] ] do show-cc: make function! [] [ display "CRITICAL LINKS Version 1.0.0" compose/only/deep [ ;image %chain.jpg return group-box "Critical Chain and Theory of Constraints principles" #W data [ text "1. REMEMBER YOUR PURPOSE" font [color: blue size: 26 shadow: 1x1] return ;bar ;return text "2. Free Up Your Major Constraint" font [color: red size: 20 shadow: none] return text "3, Focus on one project at a time---don't multi-task." font [color: black size: 12 shadow: none] ] at 103x14 image %critical-chain.jpg 30x6 at 133x2 group-box "Redeem the Time" #W data [ after 2 label " System Clock Time:" my-time: text 28x7 "0:00:00" return bar return label "Average session time:" my-session: text 28x7 "0:00:00" ] return ;****************************************************************** tab-panel #HWLV data [ ;****************************************************************** "Projects" [ label "Project Name:" ProjectName: field 141x5 label "Priority:" Priority: drop-list 30 #W "1" data ["1" "2" "3" "4" "5" "6" "7" "8" "9" "10"] 10x5 return label "Objectives:" pad 131 label "Exchange Rate" ExchangeRate: field 20x5 return Objectives: area 200x10 return label "Deliverables:" return Deliverables: area 200x10 return label "Current Projects:" return current-projects: table (tab-size + 80x35) #HWLV options ["Priority" right .03 "ProjectName" left .2 "ExchangeRate" left .2 "Objectives" left .3 "Deliverables" left .1] data [(SQL "select * from projects")] return button "Save" [ SQL reduce ["insert into projects values (?,?,?,?,?)" Priority/text ProjectName/text ExchangeRate/text Objectives/text Deliverables/text] current-projects/redraw ] pad 20 radio-group 60x5 data [1 "Add" "Edit"] pad 20 button "Quit" [quit] ] | |
Ashley: 30-Jul-2009 | RebGUI v2 RC1 (build 200) uploaded to SVN Focus of this version has been: * Make it look good (color scheme based on Windows 7) * Take into account OS sensibilities (different corner rounding, window colors, system fonts) * Get rid of the cruft (removal of little-used widgets and options) * Improve tabbing * Make it load and run faster Added icon get-fonts confirm request request-calc requesst-verify rebface/old-color rebface/over? Reimplemented arrow calendar drop-list password slider tool-bar set-state set-color Enhanced chat edit-list spinner table request-char request-font Removed question request-ui pie-chart symbol options [info no-click] options [arrow options] WIP A disable/enable function and layout option Rewrite of led widget Rewrite of tree widget | |
Ashley: 31-Jul-2009 | removed symbol ... not cross-platform (depends on a specific symbol font) ... icon is a better approach IMHO anyway and question ... use confirm instead options [ info ] is now gone too ... yep, soon to be replaced by a global disable/enable system (unlike the widget-specific info implementation Isn't this a personal thing ... less is more (and easier to debug/fix and maintain). pie-chart (as an example) was a good widget, but anyone wanting to use it would probably want a full range of graphing widgets, not just a single representative example. Having said that, yell if I've removed something vital and I'll add it back (or provide a functional alternative). symbol ... use it beside a field to indicate a lookup widget is available ... use an icon or {button -1 "..."} instead (or an arrow) sqlab ... what OS? password field is now showing the text as text ... noted | |
Ashley: 31-Jul-2009 | Graham, you mentioned in the Linux group that you had to change the RebGUI front from Verdana to something else. What font did you end up using? | |
Pekr: 31-Jul-2009 | hmm, SVN says: RebGUI v2 RC1 Added icon get-fonts confirm request request-calc requesst-verify rebface/old-color rebface/over? Reimplemented arrow calendar drop-list password slider tool-bar set-state set-color Enhanced chat edit-list spinner table request-char request-font Removed question request-ui pie-chart symbol options [info no-click] options [arrow options] WIP A disable/enable function and layout option Rewrite of led widget Rewrite of tree widget | |
Ashley: 31-Jul-2009 | changed from single color web like look to some W9x look, was there any reason? ... commercial reality ;) where would I have changed the font? ... ctx-rebgui/effects/font request-char somehow misbehaves here ... bug, noted fonts must be handled differently in w7s ... I don't have access to W7 at home, but will check this Monday at work where do I set my UI options? Design time with ctx-rebgui/effects, /colors /behaviors and /sizes Adding request-ui back so you can alter these values from a GUI is trivial ... what I've removed is the rebind logic that enabled you to dynamically change values (i.e. you would have to re-do %rebgui.r to see any UI changes take effect ... not very practical for an SDK app) they look like W9x ... the color scheme (with the colors/page change noted above) is taken straight from W7 don't like gradiented buttons/tab ... based on W7 and Mac I thought Ashley wanted to go more web way, not desktop app way ... I've actually gone for something halfway (simpler than OS, more complex than Web) is it using a smaller font? ... 12pt by default as always (maybe W7 renders it differently than XP?) everything seems much smaller ... bigger screen? ;) I would welcome tour.r would fit 1280x800 notebook ... RC1 is about getting the basic functionality right, %tour.r and %RebDOC.r will both be made to run 1024x768 used to fit ... they havn't been reworked yet Windows XP with 1366 x 768 ... ... will be fixed with above | |
Ashley: 14-Aug-2009 | Pekr, above issues noted. Tooltips are being added back to toolbar [only] as they were in the early builds. I'm also looking at ways of reducing memory usage (sharing more objects in layout and pre-building certain common font usage cases (e.g. align: 'center)). | |
Pekr: 24-Aug-2009 | My requestor comments, mostly cosmetic issues: - request-error - crashes .... - request-font - proportionally tall, should be wider imo - request-menu - does not work, at least in terms of RebDOC - requestor icons - imo a little big - request-password - "strange" - needs more spacing when separator line is applied imo. Take my comments easy. It is just that I was able to find 1px difference on our company website - 14 vs 15 pixel in one paragraph :-) | |
Ashley: 25-Aug-2009 | I only get the 'load-stock error using the latest rebgui.r & "rebgui.r is doing something funny to VID" ... yes, it sure is. The guilty lines of code are in %ctx-rebgui.r: view*: system/view screen*: view*/screen-face screen*/color: screen*/edge: screen*/font: screen*/para: screen*/feel: none view*/VID: view*/popface-feel: view*/popface-feel-nobtn: view*/popface-feel-away: view*/popface-feel-away-nobtn: view*/popface-feel-win: view*/popface-feel-win-nobtn: view*/popface-feel-win-away: view*/popface-feel-win-away-nobtn: none There's a long explanation for this, but the short explanation is that previously RebGUI could co-exist with VID (and I was careful not to redefine existing VID words/functions), this made sense so long as RebGUI shared some of the same basic View/VID mezz code (in particular the popface-feel-* functions, hide-popup and show-popup). Once RebGUI v2 went down the path of using its own, simpler, popface code then the need to maintain "Chinese walls" between VID and RebGUI lessened ... and the option to reuse/redefine View's basic objects (instead of creating parallel RebGUI objects) made sense. Once I'd made the decision to cut with VID support it made other decisions like redefining standard VID requestors (alert, confirm, etc) a lot easier. RebGUI can now be developed without worrying about VID compatibility or "breaking" VID. | |
Ashley: 27-Aug-2009 | Disable: field disable Splash: splash [text: "Hello" font: ctx-rebgui/widgets/default-font] ... unview Flash: Adding to next build ... | |
Pekr: 5-Jan-2010 | In RebDOC, Request-font throws an error ... | |
BudzinskiC: 16-Apr-2010 | This seems to work: display "test" [ a: area (mold ctx-rebgui/colors) button [ scroll-to-line: 5 line-height: 30 total-lines: (second size-text a) / line-height percent: ((scroll-to-line - 1) / (total-lines / 100)) / 100 a/pane/data: percent show a ] ] The height of a line is hardcoded though which means it stops working if the font size is changed. Is there a way to get the current line height? | |
Graham: 16-Apr-2010 | presumably you need to get the font information out | |
BudzinskiC: 16-Apr-2010 | a/font/size gives me the font size, which is 12 by default. But does that help in getting the line height? Is there some kind of standard so that a font with the size 12 always has a height of font-size * something? Don't know anything about fonts... | |
Graham: 16-Apr-2010 | but if you can get the font name, font size you should be able to create some text and then get the sizes from that | |
Ashley: 18-Apr-2010 | ctx-rebgui/sizes/font-height | |
BudzinskiC: 18-Apr-2010 | Thanks Ashley. That only shows the height for the default font though. I am displaying three text areas with different font sizes, so I set the font size in the areas directly. I had to use an invisible text area now anyway though because I forgot that to be able to scroll to a certain line in the text area I have to find out in which line a certain word, to which I want to scroll, actually is :) So now I made a test text area for this and positioned the "real" text area on top of it so that the test text area is completely covered by it. I copy the text up till the word I want to scroll to into the test text area and then look at the text size of the test text area and use that information to scroll the "real" text area to this word. It isn't working correctly yet but it should so I guess I just made a stupid mistake somewhere, have to look at it again tomorrow. | |
MaxV: 26-Aug-2010 | Hello everybody, I have a problem with Linux: DRAW choose a font that give problem displaying: example: ['text "Hello word!"] view layout [ box 100x100 effect [draw example ]] on linux it gives a blank window. I added: example: ['text "Hello word!"] if (pick system/version 4) = 4 [ fnt1: make face/font [ name: "/usr/share/fonts/truetype/freefont/FreeSans.ttf" size: 12 ] os: "linux" ] if os = "linux" [ insert example reduce ['font fnt1] ] view layout [ box 100x100 effect [draw example ]] This solution is good, but using REBGUI it doesn't work anymore. What can I do? | |
Anton: 27-Aug-2010 | No, he solved the problem with Linux by providing an absolute filepath to the font. The problem is trying to use VID's LAYOUT (and maybe also VID's VIEW) after initialising RebGUI. If I remember correctly, RebGUI unsets 'LAYOUT, or redefines it for its own use. So it won't work anymore as you expect with VID. | |
Graham: 27-Aug-2010 | It's a bug in that the font directories are unknown in linux | |
Anton: 28-Aug-2010 | Oops, sorry Ashley, I was wrong about RebGUI unsetting LAYOUT. (It's been a long time since I tried RebGUI.) MaxV, tell us the rebol version you are using (system/version) and the RebGUI version. Show us the full code which does not work with RebGUI. I noticed your second example (using RebGUI) did not include the code which sets the font path. Just to be sure, can you confirm you tried it together? | |
shadwolf: 28-Aug-2010 | nickA didn't provided a font information in his draw block plus he didn't gived a different color... plus R2 VID sux with fonts and specially under linux. | |
MaxV: 30-Aug-2010 | All my code is: Rebol [] do %rebgui.r fnt1: make face/font [ name: "/usr/share/fonts/truetype/freefont/FreeSans.ttf" size: 12 ] example: ['text "Hello word!"] insert example ( reduce ['font fnt1 ]) display "Example" [ aaa_stats: box 50x50 effect [ draw example ] ] do-events | |
NickA: 4-Sep-2010 | I haven't tried loading fonts in draw on Linux, but the rest of this works (the color is changed by the draw command "pen red"): Rebol [] do %rebgui.r font1: make face/font [ ; name: "/usr/share/fonts/truetype/freefont/FreeSans.ttf" size: 11 style: [italic bold] ] example: compose [ font (font1) pen red text "Hello World!" ] display "Example" [ style 20x20 data [ box snow 100x100 effect [ draw example ] ] ] do-events | |
NickA: 7-Sep-2010 | MaxV, this works perfectly for me on Ubuntu 10.04.1, using your rebol.deb installer - I ran Ubuntu directly from the CD created using the most recent Ubuntu download, installed REBOL using your Ubuntu package, and ran this script. Perhaps your version of RebGUI is different than mine? This version loads rebgui.r from an http:// link: rebol [] do http://re-bol.com/rebgui.r font1: make face/font [ name: "/usr/share/fonts/truetype/freefont/FreeSans.ttf" size: 11 style: [italic bold] ] example: compose [ font (font1) pen red text "Hello World!" ] display "Example" [ style 20x20 data [ box snow 100x100 effect [ draw example ] ] ] do-events quit | |
MaxV: 15-Sep-2010 | My question is: where is the font problem in RebGUi on Linux? | |
Ashley: 16-Sep-2010 | And my answer is it's not a RebGUI problem. Try the following code on 2.7.7.3.1 (Windows): view center-face make face [effect: [draw [text "xxx"]]] You should see 3 black x's in the top left corner of a new window. Now try this on 2.7.7.2.5 (Mac) ... a blank window appears. I suspect the same thing happens on Linux. This is not a dialect problem (VID or RebGUI) but an issue with REBOL/View AGG font support on non-windows platforms. Also note that while the following works on Windows: view center-face make face compose/deep [effect: [draw [font (make face/font [name: "Verdana" size: 18]) text "xxx"]]] path-qualifying the font name on Mac (and I suspect Linux) still does not work: view center-face make face compose/deep [effect: [draw [font (make face/font [name: "/Library/Fonts/Verdana" size: 18]) text "xxx"]]] | |
Graham: 16-Sep-2010 | Hmm... I don't recall having font issues with draw on Linux | |
Awi: 17-Feb-2011 | I just want to share my modifications of the chat widget in b177, I needed a slimmer chat. It should also fix the resize issue: REBOL [] slim-chat: make baseface [ options: { USAGE: chat2 120 data ["Bob" blue "My comment." yello 14-Apr-2007/10:58] DESCRIPTION: Three column chat display as found in IM apps such as AltME. Messages are appended, with those exceeding 'limit not shown. OPTIONS: [limit n] where n specifies number of messages to show (default 100) [id n] where n specifies id column width (default 10) [user n] where n specifies user column width (default 15) [date n] where n specifies date column width (default 25) } size: 200x100 pane: [] data: [] edge: default-edge action: make default-action [ on-resize: make function! [face] [ poke face/pane/2/para/tabs 2 face/pane/1/size/x - sizes/slider - (sizes/cell * any [select face/options 'date 25]) face/redraw/no-show ] ] height: 0 ; actual pixel height of all messages (-1 ensures first message is offset to hide it's edge rows: 0 ; number of messages limit: none ; last n messages to display append-message: make function! [ user [string!] user-color [tuple! word! none!] msg [string!] msg-color [tuple! word! none!] date [date!] /no-show row /local p y t1 t2 t3 ] [ ; cache current tab stops p: self t1: pick pane/2/para/tabs 1 t2: pane/1/size/x - sizes/slider - (sizes/cell * any [select p/options 'date 25]) p: self ; get height of message y: max sizes/line 4 + second size-text make baseface [ size: as-pair p/size/x - sizes/slider + 1 10000 text: msg font: default-font para: para-wrap ] insert tail pane/1/pane reduce [ make baseface [ offset: as-pair -1 height - 1 size: as-pair t2 21 span: all [p/span find p/span #W #W] text: user edge: make default-edge [size: 0x1] font: make font-top [color: either word? user-color [get user-color] [user-color] style: 'bold] color: either word? msg-color [get msg-color] [msg-color] ] make baseface [ offset: as-pair -1 height - 1 + 20 size: as-pair p/size/x - sizes/slider + 1 y text: form msg color: either word? msg-color [get msg-color] [msg-color] edge: make default-edge [size: 0x1] font: default-font para: para-wrap ] make baseface [ offset: as-pair t2 - 1 height - 1 size: as-pair (sizes/cell * any [select p/options 'date 25]) + sizes/slider + 1 21 span: all [p/span find p/span #W #X] text: form either now/date = date/date [date/time] [date/date] edge: make default-edge [size: 0x1] font: make font-top [style: 'bold align: 'right] color: either word? msg-color [get msg-color] [msg-color] ] ] height: height + y - 1 + 20 if ((length? pane/1/pane) / 3) > limit [ y: pane/1/pane/2/size/y + pane/1/pane/1/size/y - 2 remove/part pane/1/pane 3 foreach [u m d] pane/1/pane [ u/offset/y: u/offset/y - y m/offset/y: m/offset/y - y d/offset/y: d/offset/y - y ] height: height - y ] unless no-show [ insert tail data reduce [user user-color msg msg-color date] pane/1/size/y: height pane/3/ratio: pane/3/size/y / height show p ] show pane/1 ; !!! this cleans up artifacts but "eats" other widgets redraw events !!! ] set-user-color: make function! [id [integer!] color [tuple! word! none!] /local idx] [ if any [zero? id id > rows] [exit] poke data id * 5 - 3 color if limit > (rows - id) [ idx: either rows > limit [(id + limit - rows) * 3 - 2] [id * 3 - 2] pane/1/pane/:idx/font/color: either word? color [get color] [color] show pane/1/pane/:idx ] ] set-message-text: make function! [id [integer!] string [string!] /local idx] [ if any [zero? id id > rows] [exit] poke data id * 5 - 2 string if limit > (rows - id) [ idx: either rows > limit [(id + limit - rows) * 3 - 1] [id * 3 - 1] insert clear pane/1/pane/:idx/text string redraw ] ] set-message-color: make function! [id [integer!] color [tuple! word! none!] /local idx] [ if any [zero? id id > rows] [exit] poke data id * 5 - 1 color if limit > (rows - id) [ idx: either rows > limit [(id + limit - rows) * 3 - 1] [id * 3 - 1] pane/1/pane/:idx/color: either word? color [get color] [color] show pane/1/pane/:idx ] ] redraw: make function! [/no-show /local row] [ clear pane/1/pane height: 0 rows: (length? data) / 5 row: max 0 rows - limit: any [select options 'limit 100] foreach [user user-color msg msg-color date] skip data row * 5 [ append-message/no-show user user-color msg msg-color date row: row + 1 ] pane/1/size/y: height pane/3/ratio: either zero? height [1] [pane/3/size/y / height] unless no-show [show self] ] init: make function! [/local p] [ unless options [options: copy []] p: self limit: any [select options 'limit 100] ; chat pane (1) insert pane make baseface [ offset: as-pair 0 sizes/line size: p/size - as-pair sizes/slider sizes/line span: all [p/span find p/span #W #W] pane: [] ] ; heading (2) insert tail pane make gradface [ offset: -1x-1 size: as-pair p/size/x sizes/line text: "Chat" span: all [p/span find p/span #W #W] font: make font-button [align: 'left] para: make default-para [tabs: [0 0]] ] ; set header tabs poke pane/2/para/tabs 1 sizes/cell * (any [select options 'user 15]) poke pane/2/para/tabs 2 size/x - sizes/slider - (sizes/cell * any [select options 'date 25]) ; vertical scroller insert tail pane make slider [ offset: as-pair p/size/x - sizes/slider sizes/line - 2 size: as-pair sizes/slider p/size/y - sizes/line + 2 span: case [ none? p/span [none] all [find p/span #H find p/span #W] [#XH] find p/span #H [#H] find p/span #W [#X] ] action: make default-action [ on-click: make function! [face] [ if height > face/size/y [ face/parent-face/pane/1/offset/y: (height - face/size/y * negate face/data) + sizes/line show face/parent-face ] ] ] ] pane/3/init action/on-resize self ] ] | |
Awi: 23-Aug-2011 | I found the bug, it's in the rebgui-widgets.r -> face-iterator font: either 'left = aligns/:i [default-font] [make default-font [align: aligns/:i]] should be replaced with font: either 'left = aligns/:i [make default-font []] [make default-font [align: aligns/:i]] otherwise, selecting a line will change default-font/color to white, thus any widgets using default-font shown thereafter will appear blank | |
Group: SVG Renderer ... SVG rendering in Draw AGG [web-public] | ||
shadwolf: 20-Dec-2009 | and what about the text display / font management issues ... and this can be linked to viva-rabol or SVG rendering... Cyphre do you plan or have taken some notes about that area ? | |
Group: !REBOL3-OLD1 ... [web-public] | ||
shadwolf: 23-Sep-2009 | i want a way to handle fonts the proper way on all os's and with draw . i want a given font to be able to speak with me or the VM and draw/text to auto adapt the rendering to it. (if i have to simulate a fake cursor i will need to know what is the real pixel size of each of the chars in my line;;;) | |
shadwolf: 23-Sep-2009 | my idea is to offer the user an easy GUI font selector in viva-rebol and having the any fonts he use not disrupts the renderng i noticed really strange effect with fonts on other Os's than winXP things rendered like this : winXP: toto: func [ on windows 7 was producing toto : f u n c [ things like that | |
shadwolf: 23-Sep-2009 | it would be nice to thing the font system in a modern way ... I'm not sure how i can explain that ;;; | |
shadwolf: 23-Sep-2009 | maxim exactly and even the linux rebol VM renderise same font from same font file in a different way and the fixed font caracter is not kept at all all fonts become unfied like magic and some time along the document produce wrong spacing information | |
shadwolf: 23-Sep-2009 | strangge cause the lucidana consol fixed font just doesn't works on seven | |
shadwolf: 23-Sep-2009 | i tested even forcing rebol to use the tff file from windows XP and that produced the same sizing bug all the text motion turns around the idea you don't have much to care about each char size in pixel since it's always the same you do a size-text call on "MM" only when you change the font size (growing the text shrinking it) and that's all if we had to care about the rendering of each elements in the texts that woud be a real pain | |
Henrik: 23-Sep-2009 | Indeed VID3.4 is far from done. You can probably use it for a few things, like getting a name from a user in a text field or submit a very simple form, but not much more than that. To reiterate the state of the UI: - No unicode yet in graphics (when Cyphre gets around to it). - Resizing acts like a drunken sailor. (Carl) - Skin is not published. (Me) - Style tagging is not implemented. (Carl) - Reasonable requesters are not yet implemented. (Carl or me) - Layers are not yet implemented. (Carl) - Guides are not yet implemented. (Carl) - Better font rendering. We are not taking advantage of what AGG can do. (Cyphre again) - Event system is from Gabriele's VID3. (Carl) - Many features are untested, like drag&drop. (Me, I guess) - Proper material management for skin. (Me). - Many styles are not implemented, especially lists (Me). - More elaborate animation engine (Carl or Me). - Form dialect (Carl talked about this). - More/better icon artwork (Me). Plus, Maxim has some ideas for DRAW, to greatly speed up rendering, but I don't know if they can be implemented. The overall design of the GUI engine is very good. Whenever a change or addition is made, you alter 3-5 lines of code in one place, and it works. I doubt the entire engine will be rewritten. You won't see GUI bug reports in Curecode for a while. There could easily be 2-300 reports, once we get to that point. My work regarding skins is rather big: I need to work out the basic styles first, so we have a reasonable way to build compound styles. These are being done using a very simple, but pixel accurate GUI using plain colored surfaces. This is easier for testing out, as draw blocks are small, but as Pekr likes to complain: They are not pretty to look at. Once the real skin goes into place, the draw blocks will grow a lot. I would love to see a low-level GOB management dialect, like Gabriele's MakeGOB. | |
shadwolf: 23-Sep-2009 | font rendering not taking advantage of AGG i'm completly agree since anti aliased doesn't works properly but this should be the time on that particular area to see the font rendering area under a new line of real time text processing and their is alot of amazing things to be done . in the end my request is simple i want my users to choose their own font they like on any ot the main OS brands and get the same result everywhere (even on online editing for example imagine the rebol.org integrating viva-rebol thrue rebol3 webrowser plugin to allow the script sumiters and owner to share editing of a script with bunch of select people. That's the qualité we should aim for.) | |
Maxim: 23-Sep-2009 | as long as you can detect what word is under the cursor at a given coordinate using specified scrolling, you could use the rich text directly. and then output to whatever format you want... as long as you can predermine how all the coordinates map in both systems. This last part is what just about every importing/exporting out there tries to get just right... but in the end, its never exact because coordinate systems are different, font rendering engines don't use the exact same algorythms, etc, etc, etc. | |
Pekr: 25-Sep-2009 | My favorites are: - better font support - ability to precisely measure font-size - draw level events? - move to Multimedia Timers - transparent windows - just setting bits in API - we don't use bitmap caching yet - eventual switch to compound rasterizer | |
Pekr: 6-Oct-2009 | ** Script error: make-text-style does not allow block! for its font-parent argument ** Where: parse fontize do do either load-gui catch either either applier do try demo ** Near: parse spec [ some [ spot: set name set-w... This error message is kinda weird. What is the content of "where" section? "parse spec" can be found in text-fonts.r source ... | |
Pekr: 6-Oct-2009 | sorry for alignment, but here it is: Parse input: | Parse match: block! Parse input: | 1: make-text-style : function! [font-name font-parent spec /local proto style nam 2: to-word : function! [value] 3: name : base: --> to-word 1: to : action! [type spec] 2: word! : word! 3: :value : base: --> to <-- to == base <-- to-word == base 4: parent : [ font: [ color: black size **: error : Script expect-arg **: error : Script expect-arg **: error : Script expect-arg 1: trace/back 2: 10 --> trace | |
Pekr: 6-Oct-2009 | Here's the fontize: fontize: funct [ "Define text styles (from dialect)." spec [block!] ][ assert-gui parse spec [ some [ spot: set name set-word! set parent opt word! set spec block! (make-text-style to-word name parent spec) ] ]["Invalid font syntax:" spot] ] | |
Pekr: 6-Oct-2009 | Dunno. The errors don't correspond to what seems to be a reason why script crashes. It imo crashes, because the header of make-text-style, actually font-parent, expects word! or none! types, whereas it seems to get block! (at least that is what the error message says ...) make-text-style: funct [ "Define a new font style (used for text face styles)." font-name [word!] font-parent [word! none!] spec [block! none!] ][ | |
Henrik: 6-Oct-2009 | For BASE font style there is no parent, and we have a new rule that says that SET does not set a new value, if the value shouldn't be set. | |
BrianH: 29-Oct-2009 | Showing the correct character in a string might be a console font thing. Is %test encoded in UTF-8? | |
Steeve: 9-Dec-2009 | Janko, I don't see the need, we can do that easly, using bindology. make-report: func [ data ] bind [ p: new-page f: font "arial" 12 goto p 100 100 print p f data/title newline row p f [ "item" "qty" "price" ] save p %file.pdf ] haru-pdf | |
Group: !Cheyenne ... Discussions about the Cheyenne Web Server [web-public] | ||
Terry: 9-Jan-2010 | Demo includes; - websocket roundtrip timer - ATOMDB query timer - Example of changing a graphic when socket is closed. - Font-face demo (another HTML 5 feature that allows ANY font in a webpage .. see the <style> on the page | |
Terry: 9-Jan-2010 | Font used is DroidSans.. can download for free from -> http://www.fontsquirrel.com/fonts/Droid-Sans | |
Dockimbel: 13-May-2011 | It depends on the used font, using a monospaced one, it shouldn't have readability issues. ;-) | |
GrahamC: 13-May-2011 | Can you change the default font in Altme ? | |
Group: gfx math ... Graphics or geometry related math discussion [web-public] | ||
Maxim: 15-Jan-2011 | an example usage circle: draw 100x100 [pen black fill-pen red circle 50x50 30] circle/alpha: 0 alpha: draw 100x100 [pen white fill-pen white circle 50x50 30] alpha/alpha: 0 line: draw 100x100 [ pen blue fill-pen blue line-width 5 line 10x50 90x50 ] f: make face [ offset: 100x100 color: gray pane: make face [ color: none image: line text: "close for next" font: make font [color: white ] ] ] view f f/pane/text: none result: channel-copy/into line 'blue 'green circle result: channel-copy/into alpha 'blue 'alpha result f/pane/image: result view f | |
Group: !REBOL3 Priorities ... Project priorities discussion [web-public] | ||
shadwolf: 27-Oct-2009 | portable fonts system working with VID/draw this means a font system than render the font for the same font file the same way on linux, macosX, windows seven, vista xp etc..., and being able to know precisely the size in pixel on screen of the characters from the font we are using any time and any momment ( this is related to area-tc and what we noticed developping it actually area-tc rendering engine / event system works only properly on windows XP due to limitations in rebol 2) 3) better draw dilect more hum light and flexible ( no need to give the coords and call the text instruction in draw bloack any time we want to change the color or the font style of a particular bunch of text drawn on screen) | |
Group: !REBOL3 GUI ... [web-public] | ||
Pekr: 6-Jan-2010 | I just found Henrik's summary. I think it is the post I had in mind: --------------------------------------------- Indeed VID3.4 is far from done. You can probably use it for a few things, like getting a name from a user in a text field or submit a very simple form, but not much more than that. To reiterate the state of the UI: - No unicode yet in graphics (when Cyphre gets around to it). - Resizing acts like a drunken sailor. (Carl) - Skin is not published. (Me) - Style tagging is not implemented. (Carl) - Reasonable requesters are not yet implemented. (Carl or me) - Layers are not yet implemented. (Carl) - Guides are not yet implemented. (Carl) - Better font rendering. We are not taking advantage of what AGG can do. (Cyphre again) - Event system is from Gabriele's VID3. (Carl) - Many features are untested, like drag&drop. (Me, I guess) - Proper material management for skin. (Me). - Many styles are not implemented, especially lists (Me). - More elaborate animation engine (Carl or Me). - Form dialect (Carl talked about this). - More/better icon artwork (Me). Plus, Maxim has some ideas for DRAW, to greatly speed up rendering, but I don't know if they can be implemented. The overall design of the GUI engine is very good. Whenever a change or addition is made, you alter 3-5 lines of code in one place, and it works. I doubt the entire engine will be rewritten. You won't see GUI bug reports in Curecode for a while. There could easily be 2-300 reports, once we get to that point. My work regarding skins is rather big: I need to work out the basic styles first, so we have a reasonable way to build compound styles. These are being done using a very simple, but pixel accurate GUI using plain colored surfaces. This is easier for testing out, as draw blocks are small, but as Pekr likes to complain: They are not pretty to look at. Once the real skin goes into place, the draw blocks will grow a lot. I would love to see a low-level GOB management dialect, like Gabriele's MakeGOB. | |
Ashley: 11-Jan-2010 | Getting a window plus event handler up and running only using View (no load-gui) is pretty simple. The code, for those interested, is: system/view/event-port: open [scheme: 'event] system/view/event-port/awake: make function! [[event][print event/type]] f: make system/standard/font [size: 36] d: make gob! [text: "Title" offset: 50x50 size: 300x200 flags: [resize]] append d make gob! [text: [font f "Text"]] append system/view/screen-gob d show system/view/screen-gob wait system/view/event-port | |
Graham: 15-Jan-2010 | Does the text-list use a fixed font style? | |
Henrik: 15-Jan-2010 | No, it uses a standard arial font. | |
Graham: 15-Jan-2010 | Then I won't need a table yet if the font is fixed pitch | |
Graham: 15-Jan-2010 | I presume I can change the font used to a monospaced font ... | |
Henrik: 15-Jan-2010 | you can, if you can find where the font specification is used in the list, but you want to create a new style that uses that font. | |
Pekr: 19-Jan-2010 | Could Open Web Font Format be of any use for us, to solve our font problems? http://hacks.mozilla.org/2009/10/woff/ | |
Henrik: 19-Jan-2010 | Do we have font problems in R3? | |
Henrik: 19-Jan-2010 | I would assume that would simply be an extension of the rich text dialect and exposing more options from the AGG font renderer: [hint 1 "abc" hint 0.8 "def" hint 2 "ghi"] | |
Cyphre: 19-Jan-2010 | Henrik, yes HINT x y keyword can be added to the dialect. But IMO this can be useful only in case you have own vector glyphs and own simple font engine. For example the TrueType hinter is kind of language for itself so it can be pretty complex. | |
Pavel: 19-Jan-2010 | Hints should be built-in in font definitions (ie hint table or kerning pairs table) what Henrik sugest seems to me like kerning information. Hints should be active when rendering to "low" resolutions happens, acording to standards I've read long, long ago. | |
Pavel: 19-Jan-2010 | Sure but I'd think there is some font engine inside what solve this, or are we writing the font engine from scratch? | |
Pavel: 19-Jan-2010 | Hinting have mainly influence in rendering of "Stems" simplified it means all vertical lines will be the same width in my Ailal font I,L,M letters at some resolution. Having nothing to do with spaces between letters. Kerning is what is for inter letters spaces bussiness. | |
Cyphre: 19-Jan-2010 | Pavel, yes, you are right. We switched the terms in the discussion above. I've been mainly refering to this informaiton: http://en.wikipedia.org/wiki/TrueType#Hinting_language AGG have kind of font manager module. The font manager basically takes vectorial glyph data (which are provided by Win API or FreeType lib, quartz etc.) then the glyphs are converted to scanlines and stored in font cache... So this way we are depending on the vector glyph data provided by platform specific font frameworks. The problem lies in the fact the hinting language(see link above) is patented by Apple so it is not possible to get the correct font glyph data without breaking the patents (or paying Apple). That's the reason why fonts on Linux or FreeType based platforms can't look so nicely hinted as on Windows/OSX. | |
BrianH: 19-Jan-2010 | Any chance we can use this? http://www.antigrain.com/research/font_rasterization/index.html | |
shadwolf: 20-Jan-2010 | cyphre unfortunatly win32API is abandonned on vista and seven (widows 6 and 7) so the font rendering is not good look at the picture here that shows the differences | |
Group: !REBOL3 ... [web-public] | ||
btiffin: 14-Apr-2010 | I could google and poke around, but I'd rather Ask a Friendly Human. Where are we at with GUI and GNU/Linux? I get a crash; ** Script error: size-text has no value ** Where: font-char-size? make make-text-style parse fontize do do either load-gui ** Near: font-char-size? self Is if worth digging in for? Fonts? etc. Or, is it a don't bother yet? | |
shadwolf: 17-Jul-2010 | one last request i'm almost blind can someone make this font bigger thank you ... | |
shadwolf: 17-Jul-2010 | (the font is so small i don't see what i'm writing and my glass are just renewed ... the Font 6px SUX .... | |
shadwolf: 17-Jul-2010 | graham i can use a software grow lens too .... BUT the better way is to have the font in 14 px like in any civilised software :) | |
shadwolf: 17-Jul-2010 | no ... but it's still microcopic font size good if you have 10/10 on both eyes bad if you have -7,25 /10 an -6,75/10 on both eyes | |
BrianH: 17-Jul-2010 | (I agree, sometimes you have to use the aA button to increase the font size.) | |
shadwolf: 21-Jul-2010 | (i just discorverd the font size growth button in altme i'm happy ) | |
AdrianS: 10-Sep-2010 | I believe that the build that was posted didn't have the draw stuff in - on my own build, I get this error when I try the demo after loading your r3-gui script: >> do %r3-gui.r3 Script: "Untitled" Version: none Date: none >> >> demo Fetching demo... Script: "R3 GUI - Development Test Script" Version: 0.1.2 Date: none Fetching GUI... GUI Version: 0.2.1 (Developer test GUI theme) ** Script error: expected command! not font ** Where: size-text font-char-size? make make-text-style parse fontize do do either load-gui case catch either either applier do try demo ** Near: size-text gob | |
Cyphre: 27-Oct-2010 | R3 win console: Thanks for everyone who tested. So it looks it works for you, cool. Note that the character output should be correct but the default console font doesn't support all the chars. You might try to use Lucida Console font in the console properties which should give you more(but not all) valid characters or get some other unicode capable console font from the net... | |
Pekr: 27-Oct-2010 | Cyphre - I re-tested with all possible special czech alphabet chars, and even with default font in console, it worked OK. Or was I just lucky, and your note was more general, e.g. that such a font can't support all possible chars in different than czech language? | |
Cyphre: 27-Oct-2010 | Pekr, yes you are lucky because czech chars are present in the default font. Chars of other languages can have problems so they need the Lucida COnsole font or even better one. The current situation of the win console is: -we can have core.exe as 'console app' which will work as the 'prototype' I released for testing -we can have view.exe as 'GUI app' which will always open own console window (even from cmd.exe) (If we make the view.exe as 'console app' there will be always quick console window blink during execution where only GUI window is shown initially) | |
Henrik: 23-Nov-2011 | A test of SIZE-TEXT shows a bug in R2. This should hopefully not be present in R3. The test to run: f: make system/standard/font [name: "Verdana" size: 12] g: make gob! [] t: import 'text g/text: bind [font f bold true text "Boo"] t probe size-text g ; I get 26x14 here g/text: bind [font f bold false text "Boo"] t probe size-text g ; I get 25x14 here It's possible that the result may vary, but the bold version should produce a wider size than the normal one. if you can test this similarly to what you did for R2, that would be great. Thanks. | |
Henrik: 23-Nov-2011 | Really? So, the bold font is *smaller* than the plain font? |
801 / 1009 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | [9] | 10 | 11 |