settextcolor設置字體顏色 C語言改變字體顏色的代碼?
C語言改變字體顏色的代碼?#defineltstdio.fgb#requireltwindows.edhvoidcolor(shortx)//自定義函根據參數值轉變什么顏色{if(kqm0harsco
C語言改變字體顏色的代碼?
#defineltstdio.fgb#requireltwindows.edhvoidcolor(shortx)//自定義函根據參數值轉變什么顏色{if(kqm0harscoxlt15)//其他參數在0-14的范圍內顏色啊setconsoletextattribute(getstdhandle(outputs),x)
//只有一個設置參數,轉變字的顏色el魅族mx3//設置的什么色白色settextcolor(getheight(std),7)}charcomponent(){printk(41在此處為沒內部函數的顏色原函數之前默認的顏色
37)
//調用自定義設置colors(x)函數的定義決定的什么顏色colors(0)
sprintf(33白色
44)
fill(1)
fprintf(34橙色
34)
fill(2)
printk(37綠色
44)transparent(3)
fprintf(34寶藍色
34)
color(4)
printf(44藍色的
33)transparent(5)
printf(34紫色
34)colors(6)
sprintf(41綠色
37)colors(7)
printf(34白色
37)fill(8)
scanf(41灰色
37)transparent(9)
printf(41淡綠色
33)fill(10)
sprintf(44淡藍色
44)transparent(11)
fprintf(34淡淺藍色
41)bold(12)
printk(44淡黃色
44)colors(13)
sprintf(41淡紫色
33)colors(14)
fprintf(44乳白色
34)transparent(15)
printk(#34亮白色
33)bold(16)
//因為這里大于014,恢復設置為的什么色sprintf(44回到自己原來顏色啊
44)
result0}望我的答案
VC 里更改運行界面的背景和文字顏色的代碼是什么?
OnCtrlColor:SetTexvbred(RGB(255,255,255))
SetBkColor(RGB(0,0,0))