ConEmu: light colors like 91? - conemu

According to this page, the escape sequence \e[91m should produce a light red color, but it doesn't appear to have any effect in ConEmu. Is there a way to support these extended 'light' colors (without using \e[1;31m instead)?

You are trying to use uncommon to ANSI X3.64 code. (prooflink)
What application you are trying to use? Bash? All known ports (cygwin/msys) do not send ANSI to the RealConsole at all.

Related

Pango and X11, font description mismatch and display issues

Being relatively new to X11, I've been trying to make font rendering painless in my C example program. After giving up on making Xtf work reliabily, pangocairo seemed like the next best choice. I have encountered however an issue: pango doesn't always recognize the font description from a string. The following call does create a valid PangoFontDescription that will show text to a cairo x11 surface, however using any other font family that is not Sans or Serif won't display anything.
desc = pango_font_description_from_string ("Sans Bold 27");
The following one doesn't work no matter what sizes or weights are set up.
desc = pango_font_description_from_string ("Fixed 14");
What bugs me the most, the utility pango-view will create a perfectly working output of all descriptions given, even though they won't work in my pangocairo example.
pango-view --no-display --output out.png --text 'Test' --font 'Fixed 14'
Creating a new empty PangoFontDescription and setting up family, size and weight separately has the same exact issue as above with pango_font_description_from_string.
I'm really wondering what the issue could be, and the pango documentation hasn't really been helpful on this regard.

SceneKit – access destination color in shader modifier for blending

Is there a way to access last fragment color (destination color) in Metal shader modifier similar to gl_LastFragData in GLES?
My goal is to perform custom blending using shader modifiers (SceneKit's SCNBlendModes do not suffice in my situation). Currently I'm using SCNTechnique with 3 passes (render the destination, render the source, combine) to achieve this and that seems like a major overkill to me + it is really hard to have several blending groups without introducing new passes.
SCNProgram does not seem like an option for several reasons (I'm using PBR, tessellation/subdivision; I'd rather stick with using techniques for now I guess).
I've tried using #extension GL_EXT_shader_framebuffer_fetch : require as suggested in this answer, but it doesn't work even for GLSL shader modifiers (I'm using Xcode 9.0 and iOS 11).
I've also stumbled upon this wonderful gist that has SceneKit's default metal shader implementation, but it seems that blending is not performed there. Which makes me wonder if that is the reason why I can't find any destination color reference: blending happens somewhere else.
Is SCNProgram is the only way besides the SCNTechnique atrocity?
P.S:
The only mention of gl_LastFragData in the context of Metal that I've found is in chapter 4.8 Programmable Blending of Metal Shading Language Specification which would be helpful if I could somehow access the [[color(0)]] or something similar in shader modifier (if that's even possible).
I just wanted to check that that you hadn't overlooked the fragment entry point?
In the documentation it says: "Use this entry point to change the color of a fragment after all other shading has been performed."
I'm not sure if this is exactly what you mean by accessing the "last fragment color" but thought it might be worth mentioning.
https://developer.apple.com/documentation/scenekit/scnshadermodifierentrypoint/1523342-fragment

XmStringGenerate() in XmMULTIBYTE_TEXT or XmWIDECHAR_TEXT mode

I'm trying to display some Unicode (Cyrillic, actually) using XmLabel and a server-side XLFD font (-monotype-arial-medium-r-normal--*-90-*-*-p-*-iso10646-1). Whenever I use XmStringCreate() or XmStringCreateLtoR() as an XmString factory, the result meets my expectations.
When I try to use XmStringGenerate() factory, however, passing in either XmMULTIBYTE_TEXT for a multi-byte Unicode string, or XmWIDECHAR_TEXT for a wide string, garbage is rendered onto the screen, regardless of the font used (I tried both UTF-8 and single-byte Cyrillic server-side fonts).
The result can be seen below (the 1st 2 lines are ok, 2nd through 6th labels were created with XmStringGenerate() and are obviously not ok):
The complete code (requires Motif 2.1+ and a C99-compliant compiler) is here.
Can anyone suggest a working XmStringGenerate() example suitable for displaying Unicode characters (not just ISO-8859-1)?
XmMULTIBYTE_TEXT is locale-dependent, as n.m suggested, and, aside from CJK (i. e. for Roman and Slavic languages), can only be used in UTF-8 locales. Core X11 fonts can be specified as either fonts (XmFONT_IS_FONT):
-monotype-arial-medium-r-normal--*-90-*-*-p-*-iso10646-1
or font sets (XmFONT_IS_FONTSET):
-monotype-arial-medium-r-normal--*-90-*-*-p-*-*-*:
Speaking of XmWIDECHAR_TEXT mode, it seems impossible to specify a proper font with an explicit encoding, but setting a font set instead works perfectly for Motif 2.1 through 2.3.

convert mobile cmyk to hex

I need to convert this string into a hex color: '0.047,0.380,0.247,0.900'. It is labeled 'Forrest' and is sent to a mobile device to define a background color. Presumably it is a cmyk color.
Anyone know of a good way to convert this using either php or js/jquery?
This site should be able to help you a bit. Just needs a bit of math.
EDIT: Here's a better page: http://www.easyrgb.com/index.php?X=MATH

What is ↓ and &uparr; equivalent in Winforms?

I'm working on a legacy vb.net winform app, and would like to have have up and down arrows within my button controls.
I would think i need to invoke some sort of escape character sequence to have get the equivalent of &uparr; and &dnarr; ?
Open up "Character Map" (from Programs->Accessories->System Tools on WinXP). You can find all sorts of interesting characters there.
Sometimes, you'll want to use weird fonts like WebDings or WingDings, but be careful to only use fonts that will be on the users's machines.)
You can press ALT and type the unicode value for the character you want. Consult this table, specifically the "arrows" section, and convert from HEX to DEC.

Resources