Example #1
0
        static Orientation GetPanelOrientation(WebVTTWritingMode writingMode)
        {
            switch (writingMode)
            {
            case WebVTTWritingMode.Horizontal:
                return(Orientation.Horizontal);

            default:
                return(Orientation.Vertical);
            }
        }
Example #2
0
        static PanelContentDirection GetPanelAlignment(WebVTTWritingMode writingMode, IWebVTTContent content)
        {
            switch (writingMode)
            {
            case WebVTTWritingMode.Horizontal:
                switch (content.ParagraphDirection)
                {
                case WebVTTParagraphDirection.LeftToRight:
                    return(PanelContentDirection.LeftToRight);

                default:         //case WebVTTParagraphDirection.RightToLeft:
                    return(PanelContentDirection.RightToLeft);
                }

            case WebVTTWritingMode.VerticalGrowingLeft:
                return(PanelContentDirection.RightToLeft);

            default:     //case WebVTTWritingMode.VerticalGrowingRight:
                return(PanelContentDirection.LeftToRight);
            }
        }
 static PanelContentDirection GetPanelAlignment(WebVTTWritingMode writingMode, IWebVTTContent content)
 {
     switch (writingMode)
     {
         case WebVTTWritingMode.Horizontal:
             switch (content.ParagraphDirection)
             {
                 case WebVTTParagraphDirection.LeftToRight:
                     return PanelContentDirection.LeftToRight;
                 default: //case WebVTTParagraphDirection.RightToLeft:
                     return PanelContentDirection.RightToLeft;
             }
         case WebVTTWritingMode.VerticalGrowingLeft:
             return PanelContentDirection.RightToLeft;
         default: //case WebVTTWritingMode.VerticalGrowingRight:
             return PanelContentDirection.LeftToRight;
     }
 }
 static Orientation GetPanelOrientation(WebVTTWritingMode writingMode)
 {
     switch (writingMode)
     {
         case WebVTTWritingMode.Horizontal:
             return Orientation.Horizontal;
         default:
             return Orientation.Vertical;
     }
 }