If you want to use ManhwaViewer (NMV), just download the latest release here.
(Everything below this point is accurate for NMV 1.6.5 & NMV 166)
- MV (ManhwaViewer) -> The original Versions from v1.0 to v1.6.4.1, including the content system rewrite in v1.5
- NMV (NewManhwaViewer) -> Quick rewrite that doesn't impact user experience while making ManhwaViewer compatible with new internal systems and removes many bugs. This will include all versions up to 2.0/200
- ADMV (ActDirectManhwaViewer) -> A modern version using ActDirect, that uses best practices, is really compatible, efficient and configurable and makes important changes for further apps. This version will be released as ADMV 2.0/200
Traditionally ManhwaViewers releases used a v[Major].[Minor].[Patch] versioning scheme, it will continue to do so, but more compacted. For example "v1.6.5" can be reduced to "v165" without losing any information. The meaning of the numbers will not change.
- Search Bar: At the top, which can be lowered. It will be grayed out if the current "Provider" does not support search.
- Side Menu: Contains all important features. It's less frequently used if you don't change stories often.
- Optimal Settings:
- Chapter rate set to 0.5 (set to 1.0 if you don't want extra chapters without a story).
- Provider type: Choose between indirect and direct. Direct is generally better or necessary.
- Scale buttons and default width setting should be self-explanatory.
- Window modification options: Borderless, Hide Scrollbar, Stay On Top, ...
- Change your current provider using the "Provider" dropdown menu in the side menu. Included providers are AsuraToon, CoffeManga, HariManga, MangaQueen (can be slow), ManhwaClan, ... . Additional providers can be added through modding.
To read, type relevant keywords into the search bar and double-click the desired result. Restart the program if the chapter and title don't update automatically. Manual entry of the title in the side menu is possible but can cause errors.
The program takes 1-2 seconds to load initially. Images are loaded while scrolling through a chapter, avoiding additional loading times.
To mod ManhwaViewer, you need a basic understanding of Python, as the program is written in this language. The windows 7 version runs on CPython 3.10 by NulAsh with PySide2 and the windows 10-11 version runs on Python 3.12 with PySide6. All standard libraries are included.
-
Accessing the App Folder:
- Right-click on the ManhwaViewer shortcut or search result.
- Select "Open File Location".
- Navigate to the
_internal
directory and then open theextensions
folder. - Here, you can either create a new file or modify an existing one.
- For detailed information, explore the
_interal/modules/AutoProviderPlugin.py
file.
-
Working with Packages:
- Packages can be added to the
_interal/libs
folder, this location is the first python will check so you can overwrite packages. - All standard libs have been included as a pyinstaller option.
- Two key steps:
- Add
from modules.AutoProviderPlugin import AutoProviderPlugin, AutoProviderBaseLike
at the beginning of your code. - Your extensions must be a subclass of either
AutoProviderPlugin
orAutoProviderBaseLike
.
- Add
- Packages can be added to the
-
Using
AutoProviderPlugin
andAutoProviderBaseLike
Classes:AutoProviderPlugin
is the base class for all extensions.AutoProviderBaseLike
inherits fromAutoProviderPlugin
and is tailored for websites that use the same website-base as the ManhwaClan website.
-
Implementing a Simple Base-like Extension:
- Subclass
AutoProviderBaseLike
. - Your
__init__
method should accept the parameters (title
,chapter
,chapter_rate
,data_folder
,cache_folder
,provider
andnum_workers
). - Pass these parameters along with the website you've chosen as specific_provider_website (only the core url, so from
https://www.manhwaclan.com/manga
->manhwaclan.com
). - Restart the app to see your provider and test it out. Check the logs at ./_internal/data/logs.txt for errors even if everything seems to work fine.
- Subclass
-
Creating Custom Site Extensions (Advanced):
- Subclass
AutoProviderPlugin
. - Follow similar steps as Base-like extensions, but include additional error handling for e.g. logo downloads as any uncaught exception will crash the program.
- Subclass
- Internal Variables:
title
-- The current Manhwa Titleurl_title
-- The current Manhwa Title, made url safechapter
-- The current chapter, integer if it's whole and float if it's decimal.chapter_str
-- A string of the current chapterchapter_rate
-- Floatdata_folder
&chache_folder
-- Not really used for moddingprovider
-- The current provider as a string, can either be "indirect" or "direct"specific_provider_website
-- Whatever you passed to the parents init callblacklisted_websites
-- Was used for search engine providercurrent_url
-- Holds the current chapter urlclipping_space
-- Tells the program which piece of the logo image can be used as an icon (by default it is height x height)
Understanding these methods is crucial for successful modding. They play a vital role in how the application processes images and retrieves chapter URLs.
- Purpose: Determines which downloaded images qualify as "Chapter Images".
- Input: Receives a string representing an image file (e.g.,
"image003.png"
). - Output:
- Returns
file_name
(original name),file_extension
(original extension),new_name
(simplified name for internal use), and a boolean flag indicating the validity of the image.
- Returns
- Purpose: Finds the URL for the currently selected chapter based on the current chapter and title. It's an estimation method.
- Output: Returns the chapter URL as a string.
- Behavior: Utilizes class attributes for its operation.
- Purpose: Similar to
_indirect_provider
, but designed to actively search for the chapter URL. - Output: Returns the chapter URL as a string.
- Behavior: Leverages class attributes and a search mechanism.
- Purpose: Provides search results, primarily used by the search feature of the application.
- Input: Takes in a search query as text.
- Output: Returns a list in the format
[title, empty_string]
. Should returnFalse
if the method is not implemented.
- Implement a general
_search
method to streamline support for bothget_search_results
and_direct_provider
. - Avoid altering other methods to prevent application crashes.
- Custom helper methods can be created, but refrain from using specific reserved method names (listed below).
- Avoid modifying certain methods to prevent crashes.
- Helper methods can be implemented, but avoid any already used names (
__init__
,urlify
,get_logo_path
,set_title
,get_title
,set_chapter
,get_chapter
,set_chapter_rate
,get_chapter_rate
,set_provider
,get_provider
,set_current_url
,get_current_url
,set_blacklisted_websites
,get_blacklisted_websites
,chap
,next_chapter
,previous_chapter
,reload_chapter
,_handle_cache_result
,_download_logo_image
,redo_prep
,update_current_url
,_get_current_chapter_url
,check_url
,is_crawlable
,_get_url
,_google_provider
,_duckduckgo_provider
,_bing_provider
,_indirect_provider
,_direct_provider
,get_search_results
,_empty_cache
,_download_image_async
,download_images_async
,download_images
,validate_image
,cache_current_chapter
). - Included non-standard libraries:
aplustools==1.4.8.4
beautifulsoup4==4.12.2
Pillow==10.3.0
PySide6==6.6.0
Requests==2.31.0
urllib3==2.1.0
packaging==24.0
stdlib-list==0.10.0
aiohttp==3.9.5
aiofiles==23.2.1
To compatabilty:
- Windows Vista and lower are untested
- Windows 10-1703 has a different dark mode reg key (you need to set the environment variable to change themes).
- All other Windows versions should work without problems.
- Linux and Mac would need more modification but are also okay, just that I wouldn't be able to easily test them.
Open the file {install_location}/_internal/modules/AutoProviderPlugin.pyGo toline 68
or to the functionset_title
Add the line self.url_title = self.urlify(new_title)- The Classes dir was included with the executable, so it can't be fixed in compiled programs.
Open the file {install_location}/_internal/modules/Classes.pyGo to to the functionupdateProgress
Change the line while self.current_value == 0 and self.value() < 10: to if self.current_value == 0 and self.value() < 10:- The Classes dir was included with the executable, so it can't be fixed in compiled programs.
Please note that this was tested only on a fresh install with all default packages installed. Your path to success may vary.
-
Download the Source Files:
- Use git or the GitHub website to download the source files. Unpack them if necessary.
-
Install Python and Virtual Environment:
- Install pip for Python:
sudo apt-get -y install python3-pip
- Install
venv
for Python:sudo apt-get install python3.10-venv
- Create a virtual environment:
python3.10 -m venv ./.env
- Activate the virtual environment:
source ./.env/bin/activate
- Install pip for Python:
-
Install Project Requirements:
- Install the required Python packages:
pip3 install -r requirements.txt
- Install the required Python packages:
-
Install
cpulimit
(Recommended):- To prevent a stray bug from freezing your PC, install
cpulimit
:sudo apt-get install cpulimit
- To prevent a stray bug from freezing your PC, install
-
Install Qt Dependency:
- To run Qt on Ubuntu 22.04 LTS, install the necessary package:
sudo apt-get install libxcb-cursor0
- To run Qt on Ubuntu 22.04 LTS, install the necessary package:
-
Run the Application:
- Use
cpulimit
to run the application with a CPU limit:cpulimit -l 50 -- python3.10 nmv.py
- Alternatively, run the application without
cpulimit
:python3.10 nmv.py
- Use
-
Update Configuration:
- Change
os.environ['LOCALAPPDATA']
to./data
(or any other folder you want the program data to sit in) in theconfig.py
file and the startup section of the program. - Copy the directory
./default-config/modules
into./
. - (For older distributions, rename moduless -> modules, move all important folders into _internal, and avoid any os.path.abspath usage in the base paths)
- Change
-
Note on Missing Files:
- Depending on how you solved step 7, you will encounter an error about a missing file. The new version of
aplustools
should help detect other systems and handle these issues more easily. You can fix this by making the folder variables using os.path.abspath as we now don't have an absolute path anymore. The lower window corners are never rounded, which seems to be the system default so nothing I can do about that. You can also disable the default os theme check in timer_tick as it won't be able to detect anything and just throw some error (they won't crash the program, but rather clutter the log file).
- Depending on how you solved step 7, you will encounter an error about a missing file. The new version of
By following these steps, you should be able to run the application on Ubuntu 22.04 LTS.