Example #1
0
        public Brush CrearBrocha(SWPEditor.IU.Graficos.Brocha brocha)
        {
            SolidColorBrush b = new SolidColorBrush(CrearColor(((SWPEditor.IU.Graficos.BrochaSolida)brocha).Color));

            b.Freeze();
            return(b);
        }
Example #2
0
 public void RellenarRectangulo(SWPEditor.IU.Graficos.Brocha brocha, SWPEditor.IU.PresentacionDocumento.Punto inicio, SWPEditor.Dominio.TamBloque bloque)
 {
     contexto.DrawRectangle(CrearBrocha(brocha), null, new Rect(CrearPunto(inicio), CrearTam(bloque)));
 }
Example #3
0
        public void DibujarTexto(SWPEditor.IU.PresentacionDocumento.Punto posicion, SWPEditor.IU.Graficos.Letra letra, SWPEditor.IU.Graficos.Brocha brocha, string texto)
        {
            Typeface      t = new Typeface(new FontFamily(letra.Familia), new FontStyle(), new FontWeight(), new FontStretch());
            FormattedText f = new FormattedText(texto, System.Globalization.CultureInfo.InvariantCulture, FlowDirection.LeftToRight, t, ObtenerMedida(letra.TamaƱo),
                                                CrearBrocha(brocha));

            contexto.DrawText(f, CrearPunto(posicion));
        }