sebp / sebp/PyGObject-Tutorial

Feature Request: Additional Clarification on "Simple Example" in "introduction.txt"

オープン
#206 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

主要言語
Python
スター
392
フォーク
157
PR マージ指標
30日以内にマージされた PR はありません

説明

I hope this isn't too pedantic as a request, but just reading section 2.1 of the guide from the top, the first statement claims, "This program will create an empty 200 x 200 pixel window."
A graphical representation of such a window is then included.
The page then provides a 9-line program by way of an example, in source code, then follows to "explain each line of the example."

However, nowhere on this page does the text return to the subject of "200 x 200 pixel" sizing. It seems reasonable for the initial declarative statement to explain what is about to happen, but there is nothing in the sample code which defines such a size and it is therefore implied that Python's "Gtk.Window()" method, or perhaps "win.show_all()", must somehow default to these dimensions unless explicitly told otherwise.

If you're going to have a "simple example", can I respectfully request/suggest that the explanatory text be expanded just enough to tell the reader where the window dimensions come from.

I appreciate that this might come across as pedantry, but syntax is critical in programming, so in the early stages of introducing a language or framework, I would suggest that all defaults and assumptions need to be discussed.

This is all the more relevant given the second example on the Introduction Page (the ubiquitous "Hello World" application with the "Click Here" button. Miraculously, the rendered window has changed size. Yet again, there is nothing in the code to suggest window size or why this might be different from the first example. The two examples imply that if you deploy a random, empty window, then it will default to a size of 200x200 pixels, but if you deploy a window that contains an object (your second example uses a button), then the window will automatically size itself to the dimensions of the rendered contents.

None of which is explained.

Even if you want to direct your reader to set this aside, please don't leave hanging threads at the start...

Thank you

コントリビューションガイド

このリポジトリのコントリビューションガイドは索引されていません

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

調査の方向性

introduction.txt を開き、2.1 節を 2 つのウィンドウ例と併せて読んでください。現在の本文が 200 x 200 のウィンドウと、サイズの異なる Hello World ウィンドウをどのように説明しているか確認してください。これらの例を説明しないままにせず、関連するサイズ設定の動作とデフォルト値を説明できていれば、ドキュメントは完成です。

索引モデルが issue の本文から書いたものです。

評価

技術スタック
python
領域
documentation
issue の種類
ドキュメント
難易度
2/5
見積もり時間
1〜3時間
活発さ
停滞
明瞭さ
おおむね明確
初心者へのやさしさ
45/100

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。