- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I'm trying to get linedraw characters. The documentation states
"Using QWIN$EXTENDFONT_OEM_CHARSET with the font name 'MS LineDraw'C will get the old DOS-style character set with symbols that can be used to draw lines and boxes."
But it gives no instruction or example on how to use it. What I am trying is
USE IFQWIN
TYPE (Windowconfig) wc
LOGICAL status
wc%fontsize = QWIN$EXTENDFONT
wc%extendfontname = 'MS Linedraw'C
wc%extendfontattributes = QWIN$EXTENDFONT_OEM_CHARSET
status = SETWINDOWCONFIG (wc)
IF (.NOT. status) status = WINDOWCONFIG (wc)
But this does not work. I am suspicious of the assignment of QWIN$EXTENDFONT_OEM_CHARSET to wc%extendfontattributes. Just guessing on this due to lack of documentation.
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
What does "does not work" mean? What happens if you output transfer([(char(i),i=176,223)],repeat('A',48)) ?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
By "does not work" I mean that I get the same output as if the suspicious statement weren't there.
Not sure what the TRANSFER business is all about, but if I WRITE (*, *) CHAR(I) where i is any of the character addresses 176 - 223, all that displays is an odd foreign character--exactly the same as if the QWIN$EXTENDFONT_OEM_CHARSET line were missing.
I don't ever use TRANSFER, I get a compile error when I try to include your statement, and I don't understand the documentation on this function
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The program
write(*,*) transfer([(char(i),i=176,223)],repeat('A',48)) end
outputs
░▒▓│┤╡╢╖╕╣║╗╝╜╛┐└┴┬├─┼╞╟╚╔╩╦╠═╬╧╨╤╥╙╘╒╓╫╪┘┌█▄▌▐▀
which looks like line drawing characters in my preview. I have never tried quickwin and I can't get the font stuff to work at all either.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
So, I would like to ask the Intel folks: Does this feature work or not?
If so, can you please add to the documentation with either instructions how to use it, or an example?
If not, can you either fix it or remove it from the feature list?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The help had the comment below which I guess you must have read. But that is still "device dependant", ie the particular windows install would need to recognise that font name. I would imagine in your case SETWINDOWCONFIG does a best fit but does not give you what you want. The character you want are in code page 437, the old dos characters.
QWIN$EXTENDFONT_ANSI_CHARSET |
QuickWin default. |
QWIN$EXTENDFONT_OEM_CHARSET |
Use this to get Microsoft* LineDraw. |
Using QWIN$EXTENDFONT_OEM_CHARSET with the font name 'MS LineDraw'C will get the old DOS-style character set with symbols that can be used to draw lines and boxes.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
This stuff is really a holdover from DOS - it seems odd to want to use it in 2015, and as app4619 notes, it requires underlying support of the appropriate codeset.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
app4619: Thanks. I gather from your response that you actually tried it, and it worked. Otherwise your info is nothing more than what the documentation says. When you say "Using QWIN$EXTENDFONT_OEM_CHARSET with the font name 'MS LineDraw'C " what exactly do you mean? How does one "use" QWIN$EXTENDFONT_OEM_CHARSET ?
That is my problem. Take a look at my original post to see what I tried. Then, perhaps you can confirm whether I tried the right thing, or maybe you know of the "proper" way to use it.
Steve: I think I have support of the codeset, since I frequently use linedraw characters in other programs including word processors etc. What I was really hoping for is the documentation to do a better job explaining this feature that goes beyond the cryptic "use this with that." Even if this use is outdated, I would expect Intel to keep the documentation current and explain how to use the features that are included.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I agree that 'does not work' is a good description of the results I have been able to obtain so far. Perhaps it would be useful to provide a complete compilable example so as to illustrate the gap between documentation and function.
! Compile with ! ifort qwin.f90 /libs:qwin ! Get MS LineDraw from ! http://www.whollygenes.com/forums201/index.php?/topic/380-ms-linedraw-truetype-font/ ! and install by copying LINEDRAW.TTF to C:\Windows\Fonts program qwin use ifqwin implicit none type(windowconfig) wc logical res4 integer fontsize integer(2) iRowpos, iColpos type(rccoord) rc ! character(*), parameter :: NL = '' character(*), parameter :: NL = achar(0) res4 = getwindowconfig(wc) fontsize = wc%fontsize wc%extendfontname = 'MS LineDraw'//achar(0) wc%extendfontsize = fontsize wc%fontsize = QWIN$EXTENDFONT wc%extendfontattributes = QWIN$EXTENDFONT_OEM_CHARSET wc%title = 'A Title'//achar(0) res4 = setwindowconfig(wc) if(.NOT.res4) res4 = setwindowconfig(wc) iRowpos = 1 iColpos = 1 call SETTEXTPOSITION(iRowpos,iColpos,rc) call OUTTEXT(char(218)//repeat(char(196),13)//char(191)//NL) iRowpos = iRowpos+1 call SETTEXTPOSITION(iRowpos,iColpos,rc) call OUTTEXT(char(179)//'This is a box'//char(179)//NL) iRowpos = iRowpos+1 call SETTEXTPOSITION(iRowpos,iColpos,rc) call OUTTEXT(char(192)//repeat(char(196),13)//char(217)//NL) iRowpos = iRowpos+1 call SETTEXTPOSITION(iRowpos,iColpos,rc) call OUTTEXT('Press <ENTER> to continue:> ') read(*,*) end program qwin
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I can replicate RO's observation. Escalated as issue DPD200367304.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
#9 sets wc%extendfontattributes = QWIN$EXTENDFONT_OEM_CHARSET
which is #00080010 but then when the setwindowconfig is called with this we get is coming back as #80000000 which is none of the preset constants in ifqwin at a glance. I think it is an error status. We thus are foobahed. The QWIN$EXTENDFONT_OEM_CHARSET is device dependant and setwindowconfig does a 'best fit' if things don't stack up. Having said that you would expect it to work.....
Edit: PARAMETER (QWIN$EXTENDFONT_NORMAL =#80000000)
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page