Skip to content

Accessibility and scaling #308

@edwardaux

Description

@edwardaux

When applying the system accessibility size settings, the text in a Html widget gets scaled way more than a normal Text widget. Consider the following code:

import 'package:flutter/material.dart';
import 'package:flutter_html/flutter_html.dart';
import 'package:flutter_html/style.dart';

void main() {
  runApp(HtmlAccessibilityApp());
}

class HtmlAccessibilityApp extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      home: Scaffold(
        appBar: AppBar(title: Text('')),
        body: Column(
          children: [
            Text('Normal Text'),
            Html(data: 'Html Text'),
          ],
        ),
      ),
    );
  }
}

When you scale the text using iOS accessibility settings, you see the following:

Simulator Screen Shot - iPhone 11 - 2020-05-30 at 08 48 24

I mentioned this in #303 but I thought it might be worth having it's own ticket (they may end up being related).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions