OiO.lk Community platform!

Oio.lk is an excellent forum for developers, providing a wide range of resources, discussions, and support for those in the developer community. Join oio.lk today to connect with like-minded professionals, share insights, and stay updated on the latest trends and technologies in the development field.
  You need to log in or register to access the solved answers to this problem.
  • You have reached the maximum number of guest views allowed
  • Please register below to remove this limitation

What is the proper way to deal with the ressource path?

  • Thread starter Thread starter Egg
  • Start date Start date
E

Egg

Guest
I'm working with Python and multiple of my GUI Classes require some images.

Is it okay to simply add the ressource path via a constant and import it everywhere?
The other approach I was considering was to make setters for each of them and use them while initializing the App. But I feel like this creates unnecessary complexity.

Are these valid, are there other approaches?
<p>I'm working with Python and multiple of my GUI Classes require some images.</p>
<p>Is it okay to simply add the ressource path via a constant and import it everywhere?<br />
The other approach I was considering was to make setters for each of them and use them while initializing the App. But I feel like this creates unnecessary complexity.</p>
<p>Are these valid, are there other approaches?</p>
 

Latest posts

Top