本文整理汇总了C#中gbrainy.Core.Main.CairoContextEx.SetPangoLargeFontSize方法的典型用法代码示例。如果您正苦于以下问题:C# CairoContextEx.SetPangoLargeFontSize方法的具体用法?C# CairoContextEx.SetPangoLargeFontSize怎么用?C# CairoContextEx.SetPangoLargeFontSize使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类gbrainy.Core.Main.CairoContextEx
的用法示例。
在下文中一共展示了CairoContextEx.SetPangoLargeFontSize方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: Draw
public override void Draw(CairoContextEx gr, int area_width, int area_height, bool rtl)
{
base.Draw (gr, area_width, area_height, rtl);
gr.SetPangoLargeFontSize ();
gr.DrawTextCentered (0.5, DrawAreaY + 0.3, formula);
}
示例2: Draw
public override void Draw(CairoContextEx gr, int area_width, int area_height, bool rtl)
{
base.Draw (gr, area_width, area_height, rtl);
gr.DrawClock (DrawAreaX + 0.15, DrawAreaY + 0.1, figure_size,0, 0 /* No hands */);
gr.SetPangoLargeFontSize ();
gr.DrawTextCentered (0.5, DrawAreaY + 0.2 + figure_size, Translations.GetString ("Sample clock"));
}
示例3: Draw
public override void Draw(CairoContextEx gr, int area_width, int area_height, bool rtl)
{
base.Draw (gr, area_width, area_height, rtl);
gr.SetPangoLargeFontSize ();
gr.MoveTo (0.1, DrawAreaY);
gr.ShowPangoText (Translations.GetString ("Choose one of the following:"));
}
示例4: Draw
public override void Draw(CairoContextEx gr, int area_width, int area_height, bool rtl)
{
base.Draw (gr, area_width, area_height, rtl);
gr.SetPangoLargeFontSize ();
gr.MoveTo (0.1, 0.15);
gr.ShowPangoText (ServiceLocator.Instance.GetService <ITranslations> ().GetString ("Choose one of the following:"));
}
示例5: Draw
public override void Draw(CairoContextEx gr, int area_width, int area_height, bool rtl)
{
double x = DrawAreaX + 0.1;
base.Draw (gr, area_width, area_height, rtl);
gr.SetPangoLargeFontSize ();
gr.MoveTo (x, DrawAreaY + 0.22);
gr.ShowPangoText (String.Format (Translations.GetString ("x + y = {0}"), number_a + number_b));
gr.MoveTo (x, DrawAreaY + 0.44);
gr.ShowPangoText (String.Format (Translations.GetString ("have a ratio of {0}:{1}"), ratio_a, ratio_b));
}
示例6: DrawObjectToMemorize
public override void DrawObjectToMemorize(CairoContextEx gr, int area_width, int area_height, bool rtl)
{
StringBuilder sequence = new StringBuilder (64);
base.DrawObjectToMemorize (gr, area_width, area_height, rtl);
gr.SetPangoLargeFontSize ();
for (int num = 0; num < Challenge.Numbers.Length - 1; num++)
{
sequence.Append (Challenge.Numbers [num]);
sequence.Append (", ");
}
sequence.Append (Challenge.Numbers [Challenge.Numbers.Length - 1]);
gr.DrawTextCentered (0.5, DrawAreaY + 0.3, sequence.ToString ());
}
示例7: Draw
public void Draw(CairoContextEx gr, int area_width, int area_height, bool rtl)
{
gr.Scale (area_width, area_height);
gr.LineWidth = 0.01;
gr.Color = new Cairo.Color (0, 0, 0, 1);
gr.SetPangoLargeFontSize ();
gr.DrawTextCentered (0.5, 0.1, ServiceLocator.Instance.GetService <ITranslations> ().GetString ("Get ready to memorize the next objects..."));
gr.Stroke ();
gr.SetPangoFontSize (0.35);
gr.DrawTextCentered (0.5, 0.5, countdown_time.ToString ());
gr.Stroke ();
gr.Arc (0.5, 0.5, 0.25, 0, 2 * Math.PI);
gr.Stroke ();
gr.Arc (0.5, 0.5, 0.28, 0, 2 * Math.PI);
gr.Stroke ();
}
示例8: Draw
public override void Draw(CairoContextEx gr, int area_width, int area_height, bool rtl)
{
double operand_y = DrawAreaY + 0.2;
const double operand_space = 0.1;
const double aligned_pos = 0.58;
base.Draw (gr, area_width, area_height, rtl);
gr.SetPangoLargeFontSize ();
for (int i = 0; i < operands.Length - 1; i++)
{
gr.DrawTextAlignedRight (aligned_pos, operand_y, operands[i].ToString ());
gr.MoveTo (DrawAreaX + 0.2, operand_y + 0.03);
switch (operation) {
case Operation.Addition:
gr.ShowPangoText ("+");
break;
case Operation.Subtraction:
gr.ShowPangoText ("-");
break;
case Operation.Multiplication:
gr.ShowPangoText ("*");
break;
}
operand_y += operand_space;
}
gr.DrawTextAlignedRight (aligned_pos, operand_y, operands[operands.Length - 1].ToString ());
operand_y += 0.08;
gr.MoveTo (DrawAreaX + 0.2, operand_y);
gr.LineTo (DrawAreaX + 0.5, operand_y);
gr.Stroke ();
if (Answer.Draw) {
gr.DrawTextAlignedRight (aligned_pos, operand_y + 0.03, Answer.Correct);
}
}
示例9: Draw
public override void Draw(CairoContextEx gr, int area_width, int area_height, bool rtl)
{
const double aligned_pos = 0.58;
base.Draw (gr, area_width, area_height, rtl);
gr.SetPangoLargeFontSize ();
gr.DrawTextAlignedRight (aligned_pos, DrawAreaY + 0.2, number_a.ToString ());
gr.DrawTextAlignedRight (aligned_pos, DrawAreaY + 0.3, number_b.ToString ());
gr.DrawTextAlignedRight (aligned_pos, DrawAreaY + 0.4, number_c.ToString ());
gr.MoveTo (DrawAreaX + 0.2, DrawAreaY + 0.5);
gr.LineTo (DrawAreaX + 0.5, DrawAreaY + 0.5);
gr.Stroke ();
gr.DrawTextAlignedRight (aligned_pos, DrawAreaY + 0.55, total.ToString ());
gr.MoveTo (DrawAreaX + 0.2, DrawAreaY + 0.25);
gr.ShowPangoText ((Answer.Draw == true) ? oper1.ToString () : "?");
gr.MoveTo (DrawAreaX + 0.2, DrawAreaY + 0.35);
gr.ShowPangoText ((Answer.Draw == true) ? oper2.ToString () : "?");
}
示例10: Draw
public override void Draw(CairoContextEx gr, int area_width, int area_height, bool rtl)
{
double x = DrawAreaX, y = 0.05;
base.Draw (gr, area_width, area_height, rtl);
gr.MoveTo (0.05, y);
gr.SetPangoLargeFontSize ();
gr.ShowPangoText (Translations.GetString ("Numbers"));
y += 0.08;
for (int n = 0; n < numbers.Length; n++)
{
gr.MoveTo (x, y);
gr.ShowPangoText (numbers[n].ToString ());
gr.Stroke ();
x += 0.17;
}
y += 0.16;
gr.MoveTo (0.05, y);
gr.ShowPangoText (Translations.GetString ("Possible divisors"));
}
示例11: Draw
public override void Draw(CairoContextEx gr, int area_width, int area_height, bool rtl)
{
StringBuilder sequence = new StringBuilder (64);
base.Draw (gr, area_width, area_height, rtl);
gr.SetPangoLargeFontSize ();
for (int num = 0; num < max_num - 1; num++)
{
if (num == question) {
sequence.Append ("?, ");
} else {
sequence.Append (numbers[num]);
sequence.Append (", ");
}
}
sequence.Append (numbers[max_num - 1]);
gr.DrawTextCentered (0.5, DrawAreaY + 0.3, sequence.ToString ());
}
示例12: Draw
public override void Draw(CairoContextEx gr, int area_width, int area_height, bool rtl)
{
double x = DrawAreaX + 0.25;
base.Draw (gr, area_width, area_height, rtl);
gr.SetPangoLargeFontSize ();
gr.MoveTo (x, DrawAreaY + 0.22);
switch (type) {
case SubGameTypes.Addition:
gr.ShowPangoText (String.Format (ServiceLocator.Instance.GetService <ITranslations> ().GetString ("x + y = {0}"), op1));
break;
case SubGameTypes.Subtraction:
gr.ShowPangoText (String.Format (ServiceLocator.Instance.GetService <ITranslations> ().GetString ("x - y = {0}"), op1));
break;
default:
throw new InvalidOperationException ();
}
gr.MoveTo (x, DrawAreaY + 0.44);
gr.ShowPangoText (String.Format (ServiceLocator.Instance.GetService <ITranslations> ().GetString ("x * y = {0}"), op2));
}
示例13: Draw
public override void Draw(CairoContextEx gr, int area_width, int area_height, bool rtl)
{
double x = DrawAreaX + 0.1;
base.Draw (gr, area_width, area_height, rtl);
gr.SetPangoLargeFontSize ();
gr.MoveTo (x, DrawAreaY + 0.22);
gr.ShowPangoText (String.Format ("number1 + number2 = {0}", op1));
gr.MoveTo (x, DrawAreaY + 0.44);
gr.ShowPangoText (String.Format ("number1 * number2 = {0}", op2));
gr.Color = new Color (0.9, 0.9, 0.9);
gr.DrawTextCentered (0.5, DrawAreaY, "This is an extension sample");
}
示例14: DrawPossibleAnswers
public override void DrawPossibleAnswers(CairoContextEx gr, int area_width, int area_height, bool rtl)
{
double x= DrawAreaX, y = DrawAreaY + 0.085;
int pos = 0;
gr.Color = new Color (DefaultDrawingColor.R, DefaultDrawingColor.G, DefaultDrawingColor.B, 1);
if (Answer.Draw == true) {
DrawAllFigures (gr, start_x_ans, start_y);
return;
}
gr.SetPangoNormalFontSize ();
for (int i = 0; i < figures.Length; i++)
{
if (i == question_pos)
continue;
gr.MoveTo (x, y);
gr.ShowPangoText (converter.ToString (figures[i]));
if ((pos + 1) % 4 == 0) {
y += 0.1;
x = DrawAreaX;
} else {
x+= 0.25;
}
pos++;
}
base.DrawPossibleAnswers (gr, area_width, area_height, rtl);
gr.SetPangoLargeFontSize ();
gr.MoveTo (0, 0.4);
gr.ShowPangoText (Translations.GetString ("Choose one of the following:"));
gr.MoveTo (0, 0.08);
gr.ShowPangoText (Translations.GetString ("List of images shown before"));
}
示例15: Draw
public override void Draw(CairoContextEx gr, int area_width, int area_height, bool rtl)
{
const double fraction_size = 0.17;
double x = 0.5 - (fractions_num * fraction_size / 2), y = DrawAreaY + 0.3;
const double offset_x = 0.12;
base.Draw (gr, area_width, area_height, rtl);
gr.SetPangoLargeFontSize ();
for (int i = 0; i < fractions_num; i++)
{
// Numerator
gr.DrawTextAlignedRight (x + offset_x, y, fractions[i].Numerator.ToString ());
// Sign
gr.MoveTo (x, y + 0.04);
switch (fractions[i].Operation) {
case Operation.Addition:
gr.ShowPangoText ("+");
break;
case Operation.Subtraction:
gr.ShowPangoText ("-");
break;
}
gr.Stroke ();
// Line
gr.MoveTo (x + 0.05, y + 0.08);
gr.LineTo (x + offset_x + 0.02, y + 0.08);
gr.Stroke ();
// Denominator
gr.DrawTextAlignedRight (x + offset_x, y + 0.1, fractions[i].Denominator.ToString ());
x += fraction_size;
}
}